I've created a .dmg using Disk Utility from a 32 GB source drive. Now I'm back in Disk Utility in order to restore this disk image to the very same source disk it was created from. I thought it would be a simple operation, but I can't seem to wrap my head around it.
What I've tried:
- Restoring to the drive in Disk Utility and selecting the .dmg as source. I get an error every time:
Image needs to be scanned. Will restore as mounted disk image. Operation failed…
No definition of "scanned" is provided. I have verified the image successfully. - Mounting the .dmg and restoring using its device as the source. Now I get another error:
The operation couldn’t be completed. (OSStatus error 6.) Operation failed…
It also mentions that some volumes are not Apple_HFS or Apple_UFS, which seems entirely irrelevant to me since I'm not trying to restore a specific volume.
What makes me even more confused is when I then read an Apple's support article, which states:
To restore a disk image with multiple volumes to a disk, you must partition the destination disk, then restore each volume individually
This makes no sense to me. I'm working under the assumption that a "disk image" is, well, a disk image. The partition table — a piece of data that resides on the disk — has to be recreated in order to restore a disk image? That's a contradiction to me. What is going on here?
Anyway, I tried what the article suggested as well:
- Erased the destination device and created a new APFS volume. Selected this empty volume and restored to it from the mounted dmg's APFS volume. It looks like it's working, but I return later to some error "OSStatus -119930872". I don't know how to interpret that.
At this point I felt like I've misunderstood something fundamental, so I ask here.
How am I supposed to restore a disk image to the very disk it is an image of? How am I supposed to figure out the right way to do it?
MacOS 10.14.6
Most Disk Utility output can't be provided. I changed system language to English, but the application disregards it after reboot.
Update
Output of hdiutil imageinfo <file>.dmg
:
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
nx_kernel_mount:1473: : checkpoint search: largest xid 10149, best xid 10149 @ 109
Format Description: UDIF read-only
Class Name: CUDIFDiskImage
Checksum Type: CRC32
Size Information:
Compressed Ratio: 1
Total Empty Bytes: 6233303552
Sector Count: 62533296
Total Bytes: 32017047552
CUDIFEncoding-bytes-wasted: 0
Total Non-Empty Bytes: 25783744000
CUDIFEncoding-bytes-in-use: 25783744000
Compressed Bytes: 25783744000
CUDIFEncoding-bytes-total: 25783744000
Checksum Value: $B3A0A719
Segments:
0: /path/to/SanDisk Extreme Media.dmg
Partition Information:
7:
Name: GPT Header (Backup GPT Header : 8)
Partition Number: 7
Checksum Type: CRC32
Checksum Value: $4C182713
3:
Name: EFI System Partition (C12A7328-F81F-11D2-BA4B-00A0C93EC93B : 4)
Partition Number: 3
Checksum Type: CRC32
Checksum Value: $E6D2A8FA
4:
Name: <VolumeName> (Apple_APFS : 5)
Partition Number: 4
Checksum Type: CRC32
Checksum Value: $08B05B86
0:
Name: GPT Header (Primary GPT Header : 1)
Partition Number: 0
Checksum Type: CRC32
Checksum Value: $551B4391
5:
Name: (Apple_Free : 6)
Partition Number: 5
Checksum Type: CRC32
Checksum Value: $00000000
1:
Name: GPT Partition Data (Primary GPT Table : 2)
Partition Number: 1
Checksum Type: CRC32
Checksum Value: $69E12033
6:
Name: GPT Partition Data (Backup GPT Table : 7)
Partition Number: 6
Checksum Type: CRC32
Checksum Value: $69E12033
-1:
Name: Protective Master Boot Record (MBR : 0)
Partition Number: -1
Checksum Type: CRC32
Checksum Value: $4FBC01BD
2:
Name: (Apple_Free : 3)
Partition Number: 2
Checksum Type: CRC32
Checksum Value: $00000000
Format: UDRO
Backing Store Information:
URL: file:///path/to/SanDisk%20Extreme%20Media.dmg
Name: SanDisk Extreme Media.dmg
Class Name: CUDIFEncoding
Backing Store Information:
URL: file:///path/to/SanDisk%20Extreme%20Media.dmg
Name: SanDisk Extreme Media.dmg
Class Name: CBSDBackingStore
partitions:
partition-scheme: GUID
block-size: 512
partitions:
0:
partition-name: Protective Master Boot Record
partition-start: 0
partition-synthesized: true
partition-length: 1
partition-hint: MBR
1:
partition-name: GPT Header
partition-start: 1
partition-synthesized: true
partition-length: 1
partition-hint: Primary GPT Header
2:
partition-name: GPT Partition Data
partition-start: 2
partition-synthesized: true
partition-length: 32
partition-hint: Primary GPT Table
3:
partition-name:
partition-start: 34
partition-synthesized: true
partition-length: 6
partition-hint: Apple_Free
4:
partition-UUID: AE491320-617A-49C4-8885-4727B6C9E238
partition-name: EFI System Partition
partition-hint-UUID: C12A7328-F81F-11D2-BA4B-00A0C93EC93B
partition-start: 40
partition-number: 1
partition-length: 409600
partition-hint: C12A7328-F81F-11D2-BA4B-00A0C93EC93B
partition-filesystems:
FAT32: EFI
5:
partition-UUID: AA9B39E4-38A7-4456-9DD8-FBA36B123EE0
partition-name: <VolumeName>
partition-hint-UUID: 7C3457EF-0000-11AA-AA11-00306543ECAC
partition-start: 409640
partition-number: 2
partition-length: 62123616
partition-hint: Apple_APFS
partition-filesystems:
APFS: Untitled
6:
partition-name:
partition-start: 62533256
partition-synthesized: true
partition-length: 7
partition-hint: Apple_Free
7:
partition-name: GPT Partition Data
partition-start: 62533263
partition-synthesized: true
partition-length: 32
partition-hint: Backup GPT Table
8:
partition-name: GPT Header
partition-start: 62533295
partition-synthesized: true
partition-length: 1
partition-hint: Backup GPT Header
burnable: false
udif-ordered-chunks: true
Properties:
Encrypted: false
Kernel Compatible: true
Checksummed: true
Software License Agreement: false
Partitioned: false
Compressed: false
Resize limits (per hdiutil resize -limits):
min cur max
62533296 62533296 62533296
hdiutil imageinfo /path/to/image.dmg
?