Thursday January 3, 2008 11:28

Recover lost partition table using Ubuntu Live CD + gpart

Posted by shakir as Information Insemination





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..

p/s: I am now maintaining this entry in my wiki site





Tags: , ,



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

Recover lost / corrupted GRUB entry | /home/shakir

January 4th, 2008 at 2:26 am

[...] Recover lost partition table using Ubuntu Live CD + gpart Jan [...]

krzyc

September 22nd, 2009 at 3:12 am

Thanks, it works great!

cffgv

December 30th, 2009 at 10:24 pm

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

AchillesLastStand

May 3rd, 2010 at 10:33 pm

Thanks a lot, you saved my life !

Comment Form