1
Substituir disco de uma zpool
Daniel Sato edited this page 2025-10-15 12:15:36 -03:00

Como substituir um disco de uma zpool

Identificar o disco em falha:

zpool status

Exemplo:

root@pve103:~# zpool status pool: ZFS-SAS-HDD state: DEGRADED status: One or more devices have been removed. Sufficient replicas exist for the pool to continue functioning in a degraded state. action: Online the device using zpool online' or replace the device with 'zpool replace'. scan: scrub repaired 0B in 00:00:00 with 0 errors on Sun Oct 12 00:24:01 2025 config:

    NAME                                 STATE     READ WRITE CKSUM
    ZFS-SAS-HDD                          DEGRADED     0     0     0
      raidz1-0                           DEGRADED     0     0     0
        wwn-0x5000c5008fa9c15f           ONLINE       0     0     0
        wwn-0x5000c5007ef0e64f           ONLINE       0     0     0
        wwn-0x5000c5008faace5b           ONLINE       0     0     0
        **wwn-0x5000c5008faab7cf           REMOVED      0     0     0**
    special
      mirror-2                           ONLINE       0     0     0
        nvme-eui.0026b728254cc7f5-part3  ONLINE       0     0     0
        nvme-eui.0026b72825d120f5-part3  ONLINE       0     0     0
    logs
      mirror-1                           ONLINE       0     0     0
        nvme-eui.0026b728254cc7f5-part1  ONLINE       0     0     0
        nvme-eui.0026b72825d120f5-part1  ONLINE       0     0     0
    cache
      nvme-eui.0026b728254cc7f5-part2    ONLINE       0     0     0
      nvme-eui.0026b72825d120f5-part2    ONLINE       0     0     0

Substitua fisicamente o disco para um novo!

Insira o disco no nó

Liste e identifique o disco:

fdisk -l

ls -l /dev/disk/by-id/ | grep <string-commum>

Limpe o disco novo, caso necessário

Acesse a GUI do Proxmox e faça o 'wipe disk'

Substituindo disco:

zpool replace <zpool-name> /dev/disk/by-id/<old-disk> /dev/disk/by-id/<new-disk>

Exeplo de saída:

root@pve103:~# zpool status pool: ZFS-SAS-HDD state: ONLINE scan: resilvered 136K in 00:00:01 with 0 errors on Wed Oct 15 12:14:28 2025 config:

    NAME                                 STATE     READ WRITE CKSUM
    ZFS-SAS-HDD                          ONLINE       0     0     0
      raidz1-0                           ONLINE       0     0     0
        wwn-0x5000c5008fa9c15f           ONLINE       0     0     0
        wwn-0x5000c5007ef0e64f           ONLINE       0     0     0
        wwn-0x5000c5008faace5b           ONLINE       0     0     0
        wwn-0x5000c5007ef1511f           ONLINE       0     0     0
    special
      mirror-2                           ONLINE       0     0     0
        nvme-eui.0026b728254cc7f5-part3  ONLINE       0     0     0
        nvme-eui.0026b72825d120f5-part3  ONLINE       0     0     0
    logs
      mirror-1                           ONLINE       0     0     0
        nvme-eui.0026b728254cc7f5-part1  ONLINE       0     0     0
        nvme-eui.0026b72825d120f5-part1  ONLINE       0     0     0
    cache
      nvme-eui.0026b728254cc7f5-part2    ONLINE       0     0     0
      nvme-eui.0026b72825d120f5-part2    ONLINE       0     0     0

errors: No known data errors

Aguarde o Resilver terminar e estará pronto