Originally posted by DominikHoffmann:
# man disktool
No manual entry for disktool
$ disktool
disktool: Disk Arbitration Command Tool
disktool: disktool -[r][a][u][e][m][p][n][d][s][g][A][S][D][l]
deviceName [options]
You can use disktool to rename, eject, mount or unmount disks and volumes
The acceptable command line parameters are:
Information about disks:
Usage: -l -- List Disks. Lists the disks currently known and available
on the system.
Controlling arbitration:
Usage: -r -- Refresh Disk Arbitration. Causes arbitration to refresh
its internal tables and look for new mounts/unmounts.
Managing disks:
Usage: -u -- Unmount a disk (ex. disktool -u disk2)
Usage: -p -- Unmount a partition (ex. disktool -p disk1s2)
Usage: -e -- Eject a disk (ex. disktool -e disk2)
Usage: -m -- Mount a disk (ex. disktool -m disk2). Useful when a disk
has been unmounted by hand (using -p or -u parameters
Usage: -a -- Notify of mount. Adds the disk to the Disk Arbitrations
internal tables.
Useful when you have already forced the mount and want
to let applications know it.
(ex. disktool -a disk1 AFPVolName AFPFlags)
Usage: -d -- Notify of dismount. Removes the disk from Disk
Arbitration's internal tables.
Useful when you have already forced the unmount and
want to let applications know it.
(ex. disktool -d disk1)
Controlling disk parameters:
Usage: -n -- Rename volume. Renames the volume specified as the first
argument. (ex. disktool -n disk1s2 newName)
Usage: -g -- Get the hfs encoding on a volume.
(ex. disktool -g disk1s2)
Usage: -s -- Set the hfs encoding on a volume.
(ex. disktool -s disk1s2 4)
Usage: -A -- Adopts the given device into the volinfo database.
Usage: -D -- Disowns the given device from the volinfo database.
Usage: -S -- Displays the status of the device in the volinfo database.