APFS is Apple’s new file system coming sometime in 2017. In 10.12.x the disk management command line tools have been updated to recognize commands relating to APFS. diskutil
has some APFS options, one of which being changeVolumeRole
. In that verb there is a reference as to how to set the different roles the volume can be
From the manpage of diskutil:
changeVolumeRole | chrole volumeDevice roles
Change the role metadata flag bits of an existing
APFS Volume.
The roles should be any combination of one or more
of the characters busrvBUSRV in much the same man-
ner as diskutil apfs addVolume above, in which
unspecified flags are left alone, use of lower-case
causes flags to be cleared, and use of upper-case
causes flags to be set. Alternatively, clear will
remove all flags, or 0 can be used as a no-op for
scripting convenience. You should not make any
assumptions about the usage or legal combinations
of role bits.
Ownership of the affected disks is required.
But no where does it state what the roles BUSRV
are.
The role of the disk can be observed by running diskutil apfs list
APFS Container (1 found)
|
+-- Container disk2 9C36DEF6-B883-462B-A227-84F8A60E3551
====================================================
APFS Container Reference: disk2
Capacity Ceiling (Size): 255883108352 B (255.9 GB)
Capacity In Use By Volumes: 138276864 B (138.3 MB) (0.1% used)
Capacity Available: 255744831488 B (255.7 GB) (99.9% free)
|
+-< Physical Store disk0s4 13E393EF-C27E-44EC-B238-A7CA8A842F50 | ----------------------------------------------------------- | APFS Physical Store Disk: disk0s4 | Size: 255883108352 B (255.9 GB) | +-> Volume disk2s1 CC9D66C2-345C-4415-92E4-8CDE3A396180
---------------------------------------------------
APFS Volume Disk (Role): disk2s1 (No specific role)
Name: apfTest
Mount Point: /Volumes/apfTest
Capacity Consumed: 24576 B (24.6 KB)
Capacity Reserve: None
Capacity Quota: None
Cryptographic Security: None
Iterating thru the roles they translate to:
B = "Preboot"
U = "User"
S = "System"
R = "Recovery"
V = "VM"
A volume can be set with any combination of roles according to diskutil.
A volume with all roles set shows
APFS Volume Disk (Role): disk2s1 (Preboot, User, System, Recovery, VM)