Page 1 of 4 123 ... LastLast
Results 1 to 10 of 38

Thread: How to restore partition table?

  1. #1
    Join Date
    Oct 2010
    Beans
    38

    Question [Solved] How to restore partition table?

    I got swap space full error and the ubuntu version of "blue screen of death". I used Disk Utilities to delete a 2.1GB unused partition. When I tried to create a swap space partition (with Disk Utilities) it failed. In the mean time ubuntu did some security updates. When I tried to create again Disk Uilities did not complain but only created a small ~ 500 kB partition. I deleted that and reboot and got "unknown filesystem grub rescue>". I booted from a USB key successfully. Now Disk Utilities and File Browser can see all the partitions and files on the hard drive, but GParted thinks the entire hard drive is unallocated. I vaguely remember that there are two partition table on the hard drive. It may be that one of them was deleted (when I removed the ~ 500 kB partition with Disk Utilities earlier maybe?). It seems at least the other partition table is still intact since Disk Utilities and File Browser can still see all the partitions and files. Is it possible to restore the deleted or damaged partition table and make the hard drive bootable again? Thanks!
    Last edited by adummy; October 9th, 2010 at 03:24 AM.

  2. #2
    Join Date
    Nov 2005
    Beans
    91

    Re: How to restore partition table?

    Likely it didn't write everything to disk before power-off and is trying to 'help' you by marking the disk for a file system check on the next reboot. (fsck)

    If you get a copy of testdisk photorec it can sometimes find the error. It's slow the man pages are a wall of rext. Really. not fun at all until you have done it a few times.
    Lawrence Lessig - Copyright in RW/RO culture
    www.youtube.com/watch?v=byB7nKSnFBM Freedom is worth something volunteer your time, talents and dollars. How long will it last? You decide with your support.

  3. #3
    Join Date
    Oct 2010
    Beans
    38

    Question Re: How to restore partition table?

    Quote Originally Posted by iiiears View Post
    Likely it didn't write everything to disk before power-off and is trying to 'help' you by marking the disk for a file system check on the next reboot. (fsck)

    If you get a copy of testdisk photorec it can sometimes find the error. It's slow the man pages are a wall of rext. Really. not fun at all until you have done it a few times.
    Thanks for helping! I am running testdisk and it says
    test_logical:
    Partition sector doesn't have the endmark 0xAA55

    What to do next? Thanks!

  4. #4
    Join Date
    Nov 2005
    Beans
    91

    Re: How to restore partition table?

    I am not familiar with that error but a quick search turned up mention that it, might, maybe, couldbe. ought to be if the google gods are smiling, be the "Verification Boot Record. a second 'backup' descriptor if the nearly always reliable and Master Boot Record.

    What does it mean and what to do? Google or or gamble for a shot in the dark and allow testdisk to rewrite the mbr boot record as it was. Steady now.. It is all to easy to F... up - err. "make a mistake" and cast binary bits into the non-retrievable void of nothingness.

    Google a bit more and i will too for the next 20 mins and see if we can turn up something. It's almost certain i will know more than i do now.(shrugs)
    Lawrence Lessig - Copyright in RW/RO culture
    www.youtube.com/watch?v=byB7nKSnFBM Freedom is worth something volunteer your time, talents and dollars. How long will it last? You decide with your support.

  5. #5
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: How to restore partition table?

    When I use TestDisk I always refer to one or both of these links:

    http://www.cgsecurity.org/wiki/TestD...n_table_status

    http://members.iinet.net.au/~herman546/p21.html
    Back to Xorg...

    Retired.

  6. #6
    Join Date
    Oct 2010
    Beans
    38

    Question Re: How to restore partition table?

    Quote Originally Posted by iiiears View Post
    I am not familiar with that error but a quick search turned up mention that it, might, maybe, couldbe. ought to be if the google gods are smiling, be the "Verification Boot Record. a second 'backup' descriptor if the nearly always reliable and Master Boot Record.
    Yes this sounds exactly right! I suspect the File Browser and the Disk Utility do not look at that "backup" so they have no problem seeing all the partitions and files. On the other hand GParted may need that "backup" to be correct to work: right now it thinks the entire physical hard drive is unallocated - no partition at all!

    What does it mean and what to do? Google or or gamble for a shot in the dark and allow testdisk to rewrite the mbr boot record as it was. Steady now.. It is all to easy to F... up - err. "make a mistake" and cast binary bits into the non-retrievable void of nothingness.

    Google a bit more and i will too for the next 20 mins and see if we can turn up something. It's almost certain i will know more than i do now.(shrugs)
    Yes I am also googling but my google skill is really poor. I will keep trying to see if anything come up. Is there an option in testdisk to rewrite the MBR as is? I didn't see that after hit enter for "Quick Search". It only gave me options of modifying a selected partition which I don't intend to do.

    Right now I am in BIOS doing hard disk self test. So far so good.

    Thanks again!

  7. #7
    Join Date
    Nov 2005
    Beans
    91

    Re: How to restore partition table?

    Here?
    http://www.cgsecurity.org/wiki/Data_Recovery_Examples

    If your data is one of a kind database,photos or expensive Itunes, Downloaded games etc. Grab a USB enclosure and hard disk. Gddrescue and virtualbox/vmware will image it mount it and reconstruct the data after a bit of research.

    A little waiting and a guru will see this thread. Right?
    Last edited by iiiears; October 8th, 2010 at 04:40 PM.
    Lawrence Lessig - Copyright in RW/RO culture
    www.youtube.com/watch?v=byB7nKSnFBM Freedom is worth something volunteer your time, talents and dollars. How long will it last? You decide with your support.

  8. #8
    Join Date
    Oct 2010
    Beans
    38

    Question Re: How to restore partition table?

    Quote Originally Posted by drs305 View Post
    When I use TestDisk I always refer to one or both of these links:

    http://www.cgsecurity.org/wiki/TestD...n_table_status

    http://members.iinet.net.au/~herman546/p21.html
    Quote Originally Posted by iiiears View Post

    Thanks very much for the links! I will be studying...

    This seems interesting:
    http://members.iinet.net.au/~herman546/p21.html
    near the end of the web page:
    MBR Code = Write TestDisk MBR code to the first sector (similar to fdisk, includes aa55 sig too)
    --> Write a new copy of MBR code to first sector? (Y/N)
    But the earlier error was saying partition, not boot record. On the other hand the main problem is the hard disk can't boot. At any rate it should re-write whatever used to be on the hard disk, not some new default MBR (which I though fdisk does), right? (I have Ubuntu, Vista, and XP on the hard disk)

  9. #9
    Join Date
    Nov 2005
    Beans
    91

    Re: How to restore partition table?

    One of the boot records is likely right but which one?
    I don't recall any way to undo a 50/50 choice if it is the wrong one. Likely someone else can but i would be lost.
    At this point i would buy a new drive and image the old one to it. Learning what happened has got to be more interesting than T.V.
    Lawrence Lessig - Copyright in RW/RO culture
    www.youtube.com/watch?v=byB7nKSnFBM Freedom is worth something volunteer your time, talents and dollars. How long will it last? You decide with your support.

  10. #10
    Join Date
    Oct 2010
    Beans
    38

    Re: How to restore partition table?

    and this is staring at my face and I missed it at the first glance:

    http://www.cgsecurity.org/wiki/Data_Recovery_Examples

    The type of the file system is RAW - Recovery of a damaged FAT boot sector

    Analyse Disk 80 - CHS 3737 255 63 - 29313 MB (Enh BIOS mode) 1 * FAT32 0 1 1 382 254 63 6152832 [LOKAL DISK] 2 E extended LBA 383 0 1 3736 254 63 53882010 Partition sector doesn't have the endmark 0xAA55 5 L FAT32 383 1 1 3736 254 63 53881947 5 L FAT32 383 1 1 3736 254 63 53881947

Page 1 of 4 123 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •