diskutil

From wikieduonline
Jump to navigation Jump to search

diskutil list
diskutil unmountDisk /dev/disk2
diskutil apfs list
diskutil list
/dev/disk0 (internal):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                         251.0 GB   disk0
   1:                        EFI EFI                     314.6 MB   disk0s1
   2:                 Apple_APFS Container disk1         180.0 GB   disk0s2

/dev/disk1 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +180.0 GB   disk1
                                 Physical Store disk0s2
   1:                APFS Volume Macintosh HD            167.4 GB   disk1s1
   2:                APFS Volume Preboot                 75.9 MB    disk1s2
   3:                APFS Volume Recovery                1.0 GB     disk1s3
   4:                APFS Volume VM                      3.2 GB     disk1s4

With external sd card[edit]

diskutil list
/dev/disk0 (internal):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                         251.0 GB   disk0
   1:                        EFI EFI                     314.6 MB   disk0s1
   2:                 Apple_APFS Container disk1         180.0 GB   disk0s2

/dev/disk1 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +180.0 GB   disk1
                                 Physical Store disk0s2
   1:                APFS Volume Macintosh HD            148.1 GB   disk1s1
   2:                APFS Volume Preboot                 75.9 MB    disk1s2
   3:                APFS Volume Recovery                1.0 GB     disk1s3
   4:                APFS Volume VM                      10.7 GB    disk1s4

/dev/disk2 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     FDisk_partition_scheme                        *15.9 GB    disk2
   1:             Windows_FAT_32                         15.9 GB    disk2s1


After formatting disk with Disk Utility app. [1]

... 

dev/disk2 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     FDisk_partition_scheme                        *15.9 GB    disk2
   1:                 DOS_FAT_32                          15.9 GB    disk2s1


diskutil unmountDisk /dev/disk2
Unmount of all volumes on disk2 was successful

Related commands[edit]

See also[edit]

Advertising: