One of the disks in my MD RAID 1 failed, and I had it replaced. Now the system runs on /dev/sdb, /dev/sda is blank. Although the disks are not identical (SAMSUNG HD753LJ vs. SAMSUNG HD754JJ), I made sure they both have the exact same size:

Disk /dev/sda: 698.7 GiB, 750156374016 bytes, 1465149168 sectors
Disk /dev/sdb: 698.7 GiB, 750156374016 bytes, 1465149168 sectors

In order to recreate the RAID, I need to copy the partition table from sdb to sda. However, when I run "sfdisk -d /dev/sdb |sfdisk /dev/sda", I get the error message "/dev/sda6: Start sector 70266880 out of range."

This is the existing partition layout:

/dev/sdb1           2048    1050624    1048577   512M fd Linux raid autodetect
/dev/sdb2        1052672   17829888   16777217     8G fd Linux raid autodetect
/dev/sdb3       17831936   59774976   41943041    20G fd Linux raid autodetect
/dev/sdb4       59777024 1465149167 1405372144 670.1G  f W95 Ext'd (LBA)
/dev/sdb5       59779072   70264832   10485761     5G fd Linux raid autodetect
/dev/sdb6       70266880 1465147120 1394880241 665.1G 83 Linux

When trying to set up the disk layout by hand using fdisk, the result is the same: I create the three primary and the extended partition, I create the first partition inside the extended partition (so far everything completely identical), and on the second partition, it offers:

First sector (70266881-1465149167, default 70268928):

and entering 70266880, I get "Value out of range."

Any idea what is wrong here? How can I get the RAID working again?

  • Try using another fdisk command. Alternatively, you could just copy over the boot sector which includes the partition table: dd if=/dev/sdb of=/dev/sda count=1. Then run fdisk /dev/sda and just do w to rewrite the existing table which will notify the kernel of the changes.
    – wurtel
    Aug 17, 2017 at 9:52

1 Answer 1


I found at least a workaround: parted could create the partitions without complaining. Still not sure why sfdisk refused. Copying the MBR works for primary partitions, but unfortunately, it will not copy extended partitions. If all else had failed, another possibility would have been to copy the entire disk. Changes to the data during copying would have been irrelevant, since I needed only the partition structure, but it would of course have taken a while and put unnecessary load on the system.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.