Third-party SSD and HighSierra

jbestine
New Contributor III

We are seeing upgrade failures on devices that have third-party SSD's installed. This was the reply from my engineer in the field: "Mostly Samsung for iMacs and OWC/Samsung for m.2 drives." We've opened a case with Apple on this, but I'm trying to set up a query to report on these drives. I've gone through the different posts and found some Extension attributes. The only one I've been able to get working is from:

https://www.jamf.com/jamf-nation/discussions/8931/hard-drive-speed-type-extension-attribute

I can get a yes/no answer to if a device has an SSD. But I really want to know what kind of drive. I've also tried the different EA's in this post:

https://www.jamf.com/jamf-nation/discussions/4891/report-for-displaying-storage-type-hd-vs-ssd

The scripts work great if I run it on the machine. As a script for an EA, the field is blank. I see that the information is stored in Inventory/Storage/Model, but it's not reportable. I've opened a case with support, but wondering if anyone has been able to successfully report on this.

Thanks,
Jeannine

1 ACCEPTED SOLUTION

millersc
Valued Contributor

I'm using this to capture SDD Model in our iMac and laptop fleet. It's another option.

HW - HDD Type: OWC Aur SSD
#!/bin/sh

diskinfo=$( diskutil info disk0 | grep 'Device / Media Name' | awk '{print $5,$6,$7}' | tr -d 'Media' )

echo "<result>$diskinfo</result>"

View solution in original post

6 REPLIES 6

thoule
Valued Contributor II

Hi Jeannine. See if this works for you?

#!/bin/sh                                                                                                                                                                           
echo "<result>$(/usr/sbin/system_profiler SPSerialATADataType|grep Model)</result>"

millersc
Valued Contributor

I'm using this to capture SDD Model in our iMac and laptop fleet. It's another option.

HW - HDD Type: OWC Aur SSD
#!/bin/sh

diskinfo=$( diskutil info disk0 | grep 'Device / Media Name' | awk '{print $5,$6,$7}' | tr -d 'Media' )

echo "<result>$diskinfo</result>"

easyedc
Valued Contributor II

When you say

what kind of drive
what are you specifically asking? Putting this together works for me.

#!/bin/sh

type=$(system_profiler SPStorageDataType | grep "Medium Type" | awk '{print $NF}') 


echo "<result>$type</result>"

joshuasee
Contributor III

I would recommend @millerscs approach over one based on system profiler. It is likely to tread more lightly on the CPU, and will cover non-SATA drives. If you don't want to assume the boot disk is built in, use / instead of disk 0.

diskutil has a plist output option if you want precise parsing, otherwise sed could cut down on the number of commands involved:

#!/bin/bash
echo "<result>$(/usr/sbin/diskutil info / | /usr/bin/sed -En s/...Device...Media.Name:.{5}.//p)</result>"

jbestine
New Contributor III

Thank-you all! No more pulling hair.

howie_isaacks
Valued Contributor

Aura SSDs from OWC are not compatible.

https://www.macrumors.com/2017/09/26/owc-aura-ssd-macos-high-sierra/