Skip to main content
Question

Which criteria to use to determine if the boot drive is AFPS or HFS+

  • May 22, 2018
  • 2 replies
  • 9 views

c_kay
Forum|alt.badge.img+10

Have anyone figured out which criteria to use to determine if the boot drive is AFPS or HFS+

2 replies

gda
Forum|alt.badge.img+8
  • Contributor
  • May 22, 2018

jamf binary currently does not collect this information.
Use an Extension Attribute instead:

To get the filesystem name like "Journaled HFS+" or "APFS" use this:

#!/bin/sh
/usr/sbin/diskutil info -plist / | /usr/bin/xpath '//key[.="FilesystemName"]/following-sibling::*[1]/text()' 2>/dev/null

To get the filesystem type like "hfs" or "apfs" use this:

#!/bin/sh
/usr/sbin/diskutil info -plist / | /usr/bin/xpath '//key[.="FilesystemType"]/following-sibling::*[1]/text()' 2>/dev/null

emily
Forum|alt.badge.img+26
  • Hall of Fame
  • May 22, 2018

Unearth has an artifact to detect this. You can easily dump it into an EA to collect the data on recon.