lost and found ( for me ? )

fdisk: Partition table entries are not in disk order

small tips

After installing Ubuntu13.10 on /dev/sda , I have faced following warning message on /dev/sdb.
# fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xe0a4c958

  Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS/exFAT
/dev/sda2          206911   308688974   154241032    7  HPFS/NTFS/exFAT
/dev/sda3       308690944   615890943   153600000   83  Linux
/dev/sda4       615892990   976771071   180439041    5  Extended
/dev/sda5       615892992   632276991     8192000   82  Linux swap / Solaris
/dev/sda6       632279040   976771071   172246016   83  Linux

Disk /dev/sdb: 1500.3 GB, 1500301910016 bytes
255 heads, 63 sectors/track, 182401 cylinders, total 2930277168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x026acf78

  Device Boot      Start         End      Blocks   Id  System
/dev/sdb1       614422528  1024022527   204800000    7  HPFS/NTFS/exFAT
/dev/sdb2            4094   314576895   157286401    5  Extended
/dev/sdb5            4096   314576895   157286400   83  Linux

Partition table entries are not in disk order

to fix this,
# fdisk /dev/sdb

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): f
Done.

Expert 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 or after you run partprobe(8) or kpartx(8)
Syncing disks.

confirm if the error has been fixed.
# fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xe0a4c958

  Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS/exFAT
/dev/sda2          206911   308688974   154241032    7  HPFS/NTFS/exFAT
/dev/sda3       308690944   615890943   153600000   83  Linux
/dev/sda4       615892990   976771071   180439041    5  Extended
/dev/sda5       615892992   632276991     8192000   82  Linux swap / Solaris
/dev/sda6       632279040   976771071   172246016   83  Linux

Disk /dev/sdb: 1500.3 GB, 1500301910016 bytes
255 heads, 63 sectors/track, 182401 cylinders, total 2930277168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x026acf78

  Device Boot      Start         End      Blocks   Id  System
/dev/sdb1            4094   314576895   157286401    5  Extended
/dev/sdb2       614422528  1024022527   204800000    7  HPFS/NTFS/exFAT
/dev/sdb5            4096   314576895   157286400   83  Linux
#


No comments:

Post a Comment

Note: Only a member of this blog may post a comment.