LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Manually create partition table? (http://www.linuxquestions.org/questions/linux-software-2/manually-create-partition-table-397503/)

FogSwimmer 12-29-2005 04:56 AM

Manually create partition table?
 
Hi all,

For reasons beyond my comprehension my hard drive lost its partition table overnight so I cannot access anything on it at the moment.

I booted my machine using a Knoppix CD and ran gpart and testdisk to recover the partition geometry. However, gpart cannot deal with my logical and ext3 partitions, and testdisk does not find the primary partition hidden away behind the logical ones.

From the combination of both programs' output I now have the correct partition geometry. Now I would very much like to transfer it back into the MBR. Only, I don't know how to do this:

* Is it possible to manually create and install a partition table
* How do I do this without losing my data?

Any help very much appreciated, as I am desperate to save a few days' worth work on my PhD thesis...

All the best,
Jan

masand 12-29-2005 05:35 AM

well these cases do not gaurantee fool proof recovery

you can try with these options
http://www.gnulinuxclub.org/index.ph...=234&Itemid=32
this is for MBR,u can do the same with partiton table

but first u can also see some tools from
ultimatebootcd.com

regards

FogSwimmer 12-29-2005 05:43 AM

Thanks for the hint. Unfortunately my partition table is gone, so there is nothing to back up.

My question remains: is there a way to manually create and install a new one without data loss?

Thanks.

Okie 12-29-2005 05:56 AM

try cfdisk, (no guarentees) it could be a dead harddrive, i had a 160 gig Maxtor die and nothing could revive it, i tryed Maxblast, cfdisk, fdisk, i even booted knoppix and used qtparted, i thew it away and bought a new harddrive...

FogSwimmer 12-29-2005 06:07 AM

Thanks for this idea. I would have tried cfdisk next. "Would" because everything's OK again now. I changed the partition suggestions made by testdisk to my liking and wrote them to disk. All data recovered and now I'll reinstall grub... Thanks for your help!

cs-cam 12-29-2005 06:10 AM

Good call, I had the same problem yesterday, an ext3 partition (the only one on the disk) decided to report itself as a much smaller FAT16 partition. gpart worked great but you can edit the values it finds too so either tool could have done it. Glad to see you got it sorted :)

masand 12-29-2005 12:26 PM

My question remains: is there a way to manually create and install a new one without data loss?

as i mentioned in my tip that you can take bakcup of your MBR

the same stands true for your partition table
you ned to first take backup of a partiton table and see what it is having in that file
then make changes manually in that file and update your partition table

i have not done this
i will only do this on a test hdd when i get one

regards

cs-cam 12-29-2005 06:28 PM

Course there is, we just discussed tools that can do it.


All times are GMT -5. The time now is 02:43 AM.