Recover lost partition table using Ubuntu Live CD + gpart


My friend suddenly ask me for a Ubuntu Live CD and upon being asked he told me that he has not been able to boot his machine for getting the Operating System not found error. I’m posting here on how did I helped him out with the problem for documentation.

The program I used was gpart, and to use it in Ubuntu (Live CD) is to add Universe repository to /etc/apt/sources.list as this;

deb http://archive.ubuntu.com/ubuntu gutsy main restricted universe

and run this commands to install it.

ubuntu@ubuntu:~$ sudo apt-get update
ubuntu@ubuntu:~$ sudo apt-get install gpart

By running the next command, gpart will search the whole disk for possible partitions and write it’s findings to the partition table:

ubuntu@ubuntu:~$ sudo gpart /dev/sda -W /dev/sda

That’s it. Just reboot and see if your system is now bootable…

p/s: Other than gpart, testdisk can also be used for partition recovery, but i’m not covering it here..


Tags: , ,

4 Responses to “Recover lost partition table using Ubuntu Live CD + gpart”

Thanks, it works great!

my hdd have to much partitions and i want to recover one partition wich is sda1 how to do it ?

Thanks a lot, you saved my life !


Leave a Reply

Advertisement