2020-09-21 07:05:59 +00:00
|
|
|
Some commands:
|
|
|
|
|
2021-02-20 06:06:15 +00:00
|
|
|
```console
|
|
|
|
# apt install zfsutils-linux
|
|
|
|
# zpool create local /dev/xxx
|
|
|
|
# zpool list
|
|
|
|
# zfs create local/home
|
|
|
|
# zfs list
|
|
|
|
# zfs set compression=lz4 local/home
|
|
|
|
# zfs get compression
|
|
|
|
# zfs get compressratio local/home
|
|
|
|
# zfs set dedup=on local/home
|
|
|
|
# zpool get dedupratio local
|
|
|
|
# zfs set mountpoint=/home local/home
|
|
|
|
# apt install nfs-kernel-server nfs-common
|
|
|
|
# systemctl enable --now rpc-statd.service nfs-server.service
|
|
|
|
# zfs set sharenfs="rw=@10.0.1.0/24" local/home
|
|
|
|
# zfs share local/home
|
|
|
|
# zfs get sharenfs
|
|
|
|
# #Import pool after boot/cryptsetup Open
|
|
|
|
# zpool import local
|
|
|
|
# zfs snapshot local/containers/archive@backup
|
|
|
|
# zfs list -t snapshot
|
|
|
|
# zfs send local/containers/archive@backup | ssh zfs@10.0.1.1 sudo zfs recv local/lxd00/containers/archive
|
|
|
|
# zfs destroy local/containers/archive@backup
|
|
|
|
# zfs clone local/containers/archive@backup local/containers/archive-clone
|
2020-09-21 07:05:59 +00:00
|
|
|
```
|