the rebuilding of a partition table
October 25, 2003

This page is useful when your partition table is, for some reason, trashed. If nothing else is wrong with the drive or file system, you can recover all your data. Here's how.

  1. fire up Norton Utilities' DISKEDIT.EXE

  2. ensure read-only mode is disabled (Tools.. Configuration.. uncheck [ ] Read Only.. Save)

  3. select drive (Object.. Drive.. Physical Disks.. select drive.. OK)

  4. diskedit will display absolute sector 0 - the partition table

  5. press F6, to change into partition table view

  6. the partition table will be displayed

  7. erase partitions as you please by "zeroing out" (changing to zero) all the values for each partition you wish to erase. If your partition table is completely corrupted (eg. Partition Table view doesn't display what you expect, and instead displays a bunch of other numbers and partitions which you're pretty sure are wrong), then zero out all the values and start over.

  8. recreate partitions as they were:

    1. in the System field, press the spacebar until the correct partition type is displayed. For an average system this will probably be FAT32.
    2. in the Boot field, press the spacebar until the correct option is displayed. If you boot from this drive, select Yes; otherwise select No.
    3. in the starting location/Side field, enter the first side (head) of the partition. For example, the first side for the first partition on any drive is side 1.
    4. in the starting location/Cylinder field, enter the first cylinder of the partition. For example, the first cylinder for the first partition on any drive is cylinder 0.
    5. in the starting location/Sector field, enter the first sector of the partition. For example, the first sector for the first partition on any drive is sector 1.
    6. select Tools.. Advanced Recovery Mode. If prompted to write the changes to the drive, write them.
    7. inside Advanced Recovery Mode, ignore any error messages that appear. Simply memorise (or rather, copy onto a piece of paper) the number next to "Total Sectors" in the "This Partition" box. For example, the number of total sectors on the drive in the lab machine is 8401932.
    8. press Esc to exit Advanced Recovery Mode.
    9. in the Number of Sectors field, enter the number you just memorised/copied down. For example, 8401932.
    10. press Control-B to select the partition
    11. select Tools.. Recalculate Partition. Diskedit will complete the rest of that partition's entries for you.

  9. press Control-W to write the changes to the partition table

  10. recreate any other partitions using the same process as detailed above

  11. exit DISKEDIT.EXE

  12. reboot (don't skip this step)

You may now use your partition as you were previously (assuming nothing else is wrong with it, of course).

Note: if you are unable to select Tools.. Recalculate Partition.. it's because no partition is selected. Press Control-B to select a partition - when you do so, the background will go black across the line.

Note: if you get error messages when you attempt to recalculate the partition, add/remove numbers from the appropriate fields, following the above instructions, and those provided by the error messages.

The procedure to follow to nuke a partition table is here.