About 4 months ago I dual booted High Sierra with ubuntu. I dedicated 20 GB of my hard with default Disk Utility. Recently I tried to merge the partition back, but during this process it failed and after that when I boot the system, it fails to start.
What I have:
- I have a Macbook Pro 2015
- High Sierra
- Filesystem is APFS
- Encrypted with FileVault
What I don't Have:
- Access to any Mac system
What I did
- I tried to use rEFInd maybe it could see the bootable partition (FAILED)
- I tried to boot from Recovery mode (FAILED)
- I tried Network boot (FAILED)
- I tried make a bootable usb with dmg which I downloaded. I translated first to iso (FAILED)
What I want (with priority 🙂 )
- If possible to boot current system
- Some instruction how to make bootable USB (to verify whether I did anything wrong) and Reinstall
Thanks
Best Answer
I know it's while I opened this thread but I finally understand what is the problem and how to fix it.
The problem is that after merging the partitions the Disk Utility somehow destroyed the partition type (APFS partition), and changed it to 'FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFF'. There was similar questions related to my issue here and here.
I imaged the whole disk and installed the OS from scratch and with the instructions mentioned in the links I managed to mount the image and access my data. But it was possible to fix the problem without reinstalling and imaging.
Anyway here is the commands I used after installing new OS to solve the issue on the disk image.
First mount the raw image (I imaged the disk with dd).
here is my output, as you can see the third partition type is invalid.
Get information about disk layout and start and size of each partitions.
here is the output
So I just need to remove the third partition and add it again with the right GUID, I also used the start and size from previous command. the GUID for APFS partition is 7C3457EF-0000-11AA-AA11-00306543ECAC.