Sorry...I know you like to see results:
[riki@localhost ~]$ su
Password:
[root@localhost riki]# fdisk -l
Disk /dev/hda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x6f01111e
Device Boot Start End Blocks Id System
/dev/hda1 2805 9729 55625062+ 5 Extended
/dev/hda2 * 1 2804 22523098+ 7 HPFS/NTFS
/dev/hda5 2805 4372 12594928+ 83 Linux
/dev/hda6 4373 4881 4088511 82 Linux swap / Solaris
/dev/hda7 4882 9729 38941528+ 83 Linux
Partition table entries are not in disk order
[root@localhost riki]#
Now would be a good time to use the fdisk f command, from the expert menu. This is what it's designed for. Use the routine as previously posted.
The commands, in order are;
m
x
m <-- This one is not really necessary, just there so you can see the Expert menu.
f
r
p
w
Thanks OP!
[riki@localhost ~]$ su
Password:
[root@localhost riki]# fdisk /dev/hda
The number of cylinders for this disk is set to 9729.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): m
Command action
a toggle a bootable flag
b edit bsd disklabel
c toggle the dos compatibility flag
d delete a partition
l list known partition types
m print this menu
n add a new partition
o create a new empty DOS partition table
p print the partition table
q quit without saving changes
s create a new empty Sun disklabel
t change a partition's system id
u change display/entry units
v verify the partition table
w write table to disk and exit
x extra functionality (experts only)
Command (m for help): x
Expert command (m for help): m
Command action
b move beginning of data in a partition
c change number of cylinders
d print the raw data in the partition table
e list extended partitions
f fix partition order
g create an IRIX (SGI) partition table
h change number of heads
i change the disk identifier
m print this menu
p print the partition table
q quit without saving changes
r return to main menu
s change number of sectors/track
v verify the partition table
w write table to disk and exit
Expert command (m for help): f
Done.
Expert command (m for help): r
Command (m for help): p
Disk /dev/hda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x6f01111e
Device Boot Start End Blocks Id System
/dev/hda1 * 1 2804 22523098+ 7 HPFS/NTFS
/dev/hda2 2805 9729 55625062+ 5 Extended
/dev/hda5 2805 4372 12594928+ 83 Linux
/dev/hda6 4373 4881 4088511 82 Linux swap / Solaris
/dev/hda7 4882 9729 38941528+ 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.
[root@localhost riki]#