將主機上的目錄綁定給LXC容器

此時無法製作快照

mkdir /zfs/lxc

chow 100000:100000 /zfs/lxc

pct set 你的<CTID> -mp0 /zfs/lxc,mp=/data

pct set 103 -mp0 /zfs/lxc,mp=/data

cat /etc/pve/lxc/103.conf
--------------------------------------
arch: amd64
cores: 1
features: keyctl=1,nesting=1
hostname: debian-lxc
memory: 1024
mp0: /zfs/lxc,mp=/data
net0: name=eth0,bridge=vmbr1,firewall=1,gw=10.99.0.254,hwaddr=86:46:C$
ostype: debian
rootfs: local-zfs:basevol-101-disk-0/subvol-103-disk-0,size=8G
swap: 1024
unprivileged: 1
--------------------------------------------

Last updated