Link: How to Fix a Mangled Partition Table on Linux
Figure 1: Oh dear, a boot failure.
Well there I was, rebuilding a router and having a good time when I accidentally damaged the partition table on my main Linux installation, which is a GUID partition table, or GPT. Figure 1 (above) shows the cheery message that greeted me at boot.
How did this happen? I was installing Voyage Linux on a compact flash card, and while I was messing around with GParted and other filesystem tools I accidentally ran some commands on/dev/sdb, my main hard disk, instead of /dev/sdc, the compact flash card. Like, oops. I don’t know exactly which operations gummed up /dev/sdb, which would be good to know. But I don’t, so let us carry on.