Como substituir o dispositivo defeituoso no RAID5

3

Eu queria substituir um dispositivo raid5 corrompido no meu sistema linux (opensuse 13.2), mas perdi o passo de set-faulty / remover o dispositivo (/ dev / sdc1).

Então, acidentalmente, apenas mudo o dispositivo com um novo disco clonado que leva a essa saída:

 mdadm --detail /dev/md0
/dev/md0:
        Version : 1.0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 2930264896 (2794.52 GiB 3000.59 GB)
   Raid Devices : 7
  Total Devices : 6
    Persistence : Superblock is persistent

  Intent Bitmap : Internal

    Update Time : Mon Jul 13 12:04:24 2015
          State : active, degraded
 Active Devices : 6
Working Devices : 6
 Failed Devices : 0
  Spare Devices : 0

     Layout : left-symmetric
 Chunk Size : 64K

       Name : linux:0
       UUID : fd2ae851:d7376f4f:72b8032d:2931522b
     Events : 24936

Number   Major   Minor   RaidDevice State
   9       8       17        0      active sync   /dev/sdb1
   2       0        0        2      removed
   2       8       33        2      active sync   /dev/sdc1
   3       8       49        3      active sync   /dev/sdd1
   4       8       65        4      active sync   /dev/sde1
   5       8       81        5      active sync   /dev/sdf1
   7       8       97        6      active sync   /dev/sdg1

A remoção de sdc1 por mdadm --manage /dev/md0 -r /dev/sdc1 não removeu a entrada "removida" no dispositivo 2. Portanto, a matriz foi marcada como degradada.

Agora não sei como limpar o array de raid.

Edit: Aqui está a saída do mdadm --examine / dev / sd? 1:

/dev/sdb1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x9
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : 943b936b:57015945:ee697339:e7b51539

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors - bad blocks present.
       Checksum : fc05a9a3 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 0
   Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)
/dev/sdc1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x1
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : 067ee8d8:b84ef028:edf40cb0:c5623351

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : dba97145 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 2
 Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)
/dev/sdd1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x1
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : ca751de8:dbb68f99:c741dcad:562058c0

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : c871db99 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 3
   Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)
/dev/sde1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x1
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : b43c31d2:e4eeb74b:fe239884:7acc8f89

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : 4a168e8 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 4
Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)
/dev/sdf1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x1
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : acaa467e:9ec70468:ccf75f20:2aa6a058

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : 37dc5d18 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 5
   Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)
/dev/sdg1:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x1
     Array UUID : fd2ae851:d7376f4f:72b8032d:2931522b
           Name : linux:0
  Creation Time : Tue Dec 10 19:07:16 2013
     Raid Level : raid5
   Raid Devices : 7

 Avail Dev Size : 5860529896 (2794.52 GiB 3000.59 GB)
     Array Size : 17581589376 (16767.11 GiB 18003.55 GB)
  Used Dev Size : 5860529792 (2794.52 GiB 3000.59 GB)
   Super Offset : 5860530160 sectors
   Unused Space : before=0 sectors, after=344 sectors
          State : clean
    Device UUID : 710a4e23:ccad2620:5be95df1:8f868bbc

Internal Bitmap : -24 sectors from superblock
    Update Time : Mon Jul 13 12:06:38 2015
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : c9ee7501 - correct
         Events : 24938

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 6
   Array State : A.AAAAA ('A' == active, '.' == missing, 'R' == replacing)

Obrigado pela sua ajuda!

    
por user3308110 13.07.2015 / 15:05

0 respostas