Last active
February 14, 2021 06:56
-
-
Save rctphone/62f75cf2f0293bdc9dd27eebac1d5c61 to your computer and use it in GitHub Desktop.
How to solve "APFS inverter failed to invert the volume" error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
After cloning APFS drives using Disk Utility it usually ends with a volume containing ContainerToInvert file with the size of a cloned partition. | |
Don't be afraid, using the following steps you can mount this file as APFS container and get all partitions. | |
1. Requirements | |
We need FUSE and xmount installed | |
2. Terminal | |
Open Terminal app and type the following: | |
$ sudo mkdir /Volumes/apfs_image/ | |
$ sudo mkdir /Volumes/apfs_mounted/ | |
$ sudo xmount --in raw <path to ContainerToInvert file> --out dmg /Volumes/apfs_image/ | |
$ hdiutil attach -nomount /Volumes/apfs_image/ContainerToInvert.dmg | |
$ diskutil ap list | |
## this is optional step, I don't need it | |
$ diskutil ap unlockVolume <Disk GUID> -nomount | |
$ sudo mount_apfs -o rdonly,noexec,noowners /dev/disk# /Volumes/apfs_mounted/ | |
After that, you will have the original partition mounted to your system. | |
References and Thank You’s | |
https://www.mac4n6.com/blog/2017/11/26/mount-all-the-things-mounting-apfs-and-4k-disk-images-on-macos-1013 |
I've been using the code above, still the files I found in my ContainerToInvert are corrupt or at least, I can not open them. mehrdata's way did not work for me either.. still the files seem to be corrupt :-/
any ideas?
Super helpful! Thank you!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Should work without need for
xmount
and is simpler