zfs文件查看命令
[root@thevtl ~]# zfs list NAME USED AVAIL REFER MOUNTPOINT vpool 41.4T 114G 438K /vpool vpool/vtl 41.4T 114G 438K /vpool/vtl vpool/vtl/vol01 301G 396G 18.6G - vpool/vtl/vol02 41.1T 41.2T 27.2G - [root@thevtl ~]# zpool list NAME SIZE ALLOC FREE CKPOINT EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT vpool 63.7T 70.2G 63.6T - - 0% 0% 1.00x ONLINE - [root@thevtl ~]# zpool status pool: vpool state: ONLINE config: NAME STATE READ WRITE CKSUM vpool ONLINE 0 0 0 draid2:5d:7c:0s-0 ONLINE 0 0 0 c0t2d2 ONLINE 0 0 0 c0t2d3 ONLINE 0 0 0 c0t2d4 ONLINE 0 0 0 c0t2d5 ONLINE 0 0 0 c0t2d6 ONLINE 0 0 0 c0t2d7 ONLINE 0 0 0 c0t2d8 ONLINE 0 0 0
字段解读:
draid2:允许坏两块盘,类似于raid6(draid1-3表示可容错盘数,zfs最大可容错3块盘【draid3】)
5d:5块可用硬盘 (默认最大8块)
7c:共计7块硬盘(该存储池的硬盘总数)
0s:0块热备盘(最大可设置为4)
-0:编号0
# zpool create tank draid:4d:1s:11c /dev/sd[a-k] # zpool status tank pool: tank state: ONLINE config: NAME STATE READ WRITE CKSUM tank ONLINE 0 0 0 draid1:4d:11c:1s-0 ONLINE 0 0 0 sda ONLINE 0 0 0 sdb ONLINE 0 0 0 sdc ONLINE 0 0 0 sdd ONLINE 0 0 0 sde ONLINE 0 0 0 sdf ONLINE 0 0 0 sdg ONLINE 0 0 0 sdh ONLINE 0 0 0 sdi ONLINE 0 0 0 sdj ONLINE 0 0 0 sdk ONLINE 0 0 0 spares draid1-0-0 AVAIL # echo offline >/sys/block/sdg/device/state # zpool replace -s tank sdg draid1-0-0 # zpool status pool: tank state: DEGRADED status: One or more devices is currently being resilvered. The pool will continue to function, possibly in a degraded state. action: Wait for the resilver to complete. scan: resilver (draid1:4d:11c:1s-0) in progress since Tue Nov 24 14:34:25 2020 3.51T scanned at 13.4G/s, 1.59T issued 6.07G/s, 6.13T total 326G resilvered, 57.17% done, 00:03:21 to go config: NAME STATE READ WRITE CKSUM tank DEGRADED 0 0 0 draid1:4d:11c:1s-0 DEGRADED 0 0 0 sda ONLINE 0 0 0 (resilvering) sdb ONLINE 0 0 0 (resilvering) sdc ONLINE 0 0 0 (resilvering) sdd ONLINE 0 0 0 (resilvering) sde ONLINE 0 0 0 (resilvering) sdf ONLINE 0 0 0 (resilvering) spare-6 DEGRADED 0 0 0 sdg UNAVAIL 0 0 0 draid1-0-0 ONLINE 0 0 0 (resilvering) sdh ONLINE 0 0 0 (resilvering) sdi ONLINE 0 0 0 (resilvering) sdj ONLINE 0 0 0 (resilvering) sdk ONLINE 0 0 0 (resilvering) spares draid1-0-0 INUSE currently in use # zpool replace tank sdg sdl # zpool status pool: tank state: DEGRADED status: One or more devices is currently being resilvered. The pool will continue to function, possibly in a degraded state. action: Wait for the resilver to complete. scan: resilver in progress since Tue Nov 24 14:45:16 2020 6.13T scanned at 7.82G/s, 6.10T issued at 7.78G/s, 6.13T total 565G resilvered, 99.44% done, 00:00:04 to go config: NAME STATE READ WRITE CKSUM tank DEGRADED 0 0 0 draid1:4d:11c:1s-0 DEGRADED 0 0 0 sda ONLINE 0 0 0 (resilvering) sdb ONLINE 0 0 0 (resilvering) sdc ONLINE 0 0 0 (resilvering) sdd ONLINE 0 0 0 (resilvering) sde ONLINE 0 0 0 (resilvering) sdf ONLINE 0 0 0 (resilvering) spare-6 DEGRADED 0 0 0 replacing-0 DEGRADED 0 0 0 sdg UNAVAIL 0 0 0 sdl ONLINE 0 0 0 (resilvering) draid1-0-0 ONLINE 0 0 0 (resilvering) sdh ONLINE 0 0 0 (resilvering) sdi ONLINE 0 0 0 (resilvering) sdj ONLINE 0 0 0 (resilvering) sdk ONLINE 0 0 0 (resilvering) spares draid1-0-0 INUSE currently in use
参考链接:https://openzfs.github.io/openzfs-docs/Basic%20Concepts/dRAID%20Howto.html
标签:tank,vpool,zfs,draid1,ONLINE,DEGRADED,科普,resilvering From: https://www.cnblogs.com/santia-god/p/17102555.html