Main Page - Log in -

Partition editing

From Noah.org

Jump to: navigation, search

sfdisk

On Ubuntu you may have to install the util-linux package:

aptitude install util-linux

Backup extended partition table

sfdisk -d /dev/hda > /tmp/hda

Restore extended partition table

sfdisk /dev/hda < /tmp/hda

Note that you can edit /tmp/hda between Backup and Restore. You can use this to extend the last partition if you imaged from a smaller drive to a larger drive. You cannot use this to manipulate partitions in the middle without destroying their contents.



-->