On 3/15/2018 10:28 AM, Gary Stainburn wrote:
On Thursday 15 March 2018 13:59:39 Juan Martinez wrote:
Hi Gary,

You should use parted instead of fdisk to create the GPT and its
partitions. It should be able to handle larger partitions than fdisk.

Are you using mdadm for the RAID1 array?
I ended up using the following to clone the GPT table, and checked using 
parted and it looked correct (sda and sdb match)

Yes I am using mdadm to control the RAID1 array. From all of the pages that I 
have found, it should now be a case of going through each of my 'md' devices 
and removing the dead partition and adding a new one.  What I'm not sure 
about is how to remove the 'removed' entries, or whether they'll just 
disappear once I add the replacement.

For example I have:

[root@lou log]# mdadm --detail /dev/md124
/dev/md124:
        Version : 1.2
  Creation Time : Thu Jun  5 11:16:44 2014
     Raid Level : raid1
     Array Size : 2770227008 (2641.89 GiB 2836.71 GB)
  Used Dev Size : 2770227008 (2641.89 GiB 2836.71 GB)
   Raid Devices : 2
  Total Devices : 1
    Persistence : Superblock is persistent

  Intent Bitmap : Internal

    Update Time : Wed Mar 14 21:37:24 2018
          State : active, degraded 
 Active Devices : 1
Working Devices : 1
 Failed Devices : 0
  Spare Devices : 0

           Name : var_bacula
           UUID : 2d9ba248:b6d1236a:cf9ebd49:918bad94
         Events : 1275274

    Number   Major   Minor   RaidDevice State
       0       8        2        0      active sync   /dev/sda2
       1       0        0        1      removed
[root@lou log]# 

To add the replacement device I should enter 

From everything I know I think I should enter

mdadm /dev/md124 --manage --add /dev/sdb2

as the two drives have identical partition tables, so sdb2 would match the 
existing /dev/sda2.

An I correct, and will that replace the 'removed' line?

Presumably, I then simply follow the same rule for my remaining md devices?

/dev/md125
/dev/md126
/dev/md127
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-leave@lists.fedoraproject.org

If that doesn't work try: 'mdadm /dev/md124 --re-add /dev/sdb2'.

Bill