I'm using Cent OS 6.5.
I have two Hard Drive which are exact copies of each others (/dev/sda and /dev/sdb).
/dev/sda failed and had to be replaced.
I am trying to copies everything from /dev/sdb to /dev/sda.
When I try to execute the command sfdisk -d /dev/sdb | sfdisk /dev/sda, I get the following result :
Checking that no-one is using this disk right now ...
OK
Disk /dev/sda: 121601 cylinders, 255 heads, 63 sectors/track
Old situation:
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0
Device Boot Start End #cyls #blocks Id System
/dev/sda1 0 - 0 0 0 Empty
/dev/sda2 0 - 0 0 0 Empty
/dev/sda3 0 - 0 0 0 Empty
/dev/sda4 0 - 0 0 0 Empty
New situation:
Units = sectors of 512 bytes, counting from 0
Device Boot Start End #sectors Id System
/dev/sda1 * 4096 41947135 41943040 fd Linux raid autodetect
/dev/sda2 41947136 1952468991 1910521856 fd Linux raid autodetect
/dev/sda3 1952468992 1953519615 1050624 82 Linux swap / Solaris
/dev/sda4 0 - 0 0 Empty
Warning: partition 1 does not end at a cylinder boundary
sfdisk: I don't like these partitions - nothing changed.
(If you really want this, use the --force option.)
parted -l returns the following :
Model: ATA Hitachi HUA72201 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
Model: ATA ST1000DM003-9YN1 (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: msdos
Number Start End Size Type File system Flags
1 2097kB 21.5GB 21.5GB primary ext4 boot, raid
2 21.5GB 1000GB 978GB primary ext4 raid
3 1000GB 1000GB 538MB primary linux-swap(v1)
I have also tried sgdisk -R=/dev/sda /dev/sdb but the command returns absolutely no output or error message.
What should I be doing?