Veranstaltungen/2009-12-04 ZFS-Workshop/Szenario: Ausfall einer Festplatte

Aus UUGRN
zpool status
  pool: tank
 state: DEGRADED
 scrub: resilver completed after 0h0m with 0 errors on Tue Apr 22 14:54:50 2008
config:

        NAME           STATE     READ WRITE CKSUM
        tank           DEGRADED     0     0     0
          mirror       ONLINE       0     0     0
            c0t1d0     ONLINE       0     0     0
            c1t1d0     ONLINE       0     0     0
          mirror       ONLINE       0     0     0
            c0t2d0     ONLINE       0     0     0
            c1t2d0     ONLINE       0     0     0
          mirror       DEGRADED     0     0     0
            c0t3d0     ONLINE       0     0     0
            c1t3d0     OFFLINE      0     0     0

errors: No known data errors

Das Device wird vom Pool entfernt...

zpool offline tank c1t3d0

...die Festplatte ausgetauscht...

zpool online tank c1t3d0
zpool replace tank c1t3d0

... und wieder in den Pool aufgenommen.

zpool status
  pool: tank
 state: ONLINE
 scrub: resilver completed after 0h0m with 0 errors on Tue Apr 22 14:44:46 2008
config:

        NAME        STATE     READ WRITE CKSUM
        tank        ONLINE       0     0     0
          mirror    ONLINE       0     0     0
            c0t1d0  ONLINE       0     0     0
            c1t1d0  ONLINE       0     0     0
          mirror    ONLINE       0     0     0
            c0t2d0  ONLINE       0     0     0
            c1t2d0  ONLINE       0     0     0
          mirror    ONLINE       0     0     0
            c0t3d0  ONLINE       0     0     0
            c1t3d0  ONLINE       0     0     0

errors: No known data errors

Der Rest geschieht durch Magie.

Wenn wir glücklich sind:

zpool clear tank

(Setzt den Fehler-Counter zurück und markiert den Pool als "OK")


Quellen: