Note
The Funtoo Linux project has transitioned to "Hobby Mode" and this wiki is now read-only.
Difference between revisions of "LXD/Storage Pools"
< LXD
Jump to navigation
Jump to search
(Created page with "This page lists information on the creation of LXD storage pools. A BTRFS storage pool can be created using the following command: {{console|body= # ##i##emerge btrfs-progs...") |
|||
(3 intermediate revisions by the same user not shown) | |||
Line 8: | Line 8: | ||
# ##i##lxc storage set btrfs-1tb-1 btrfs.mount_options compress=lzo | # ##i##lxc storage set btrfs-1tb-1 btrfs.mount_options compress=lzo | ||
}} | }} | ||
For ZFS, compression should be enabled by default: | |||
{{console|body= | |||
# ##i##lxc storage create zfs-1tb-1 zfs source=/dev/sdb | |||
}} | |||
For more control over your storage pool, you can create it first using ZFS, and then add it as follows: | |||
{{console|body= | |||
# ##i##zpool create -f lxd-pool /dev/sda /dev/sdb | |||
# ##i##zfs set compression=zstd lxd-pool | |||
# ##i##lxc storage create lxd-pool zfs source=lxd-pool | |||
Storage pool lxd-pool created | |||
# | |||
}} | |||
The above example creates a striped zpool and allows compression to be set explicitly to your preferred setting (there is no easy way I can find to create a striped zpool using the {{c|lxc storage create}} command directly.) |
Latest revision as of 02:51, March 28, 2023
This page lists information on the creation of LXD storage pools.
A BTRFS storage pool can be created using the following command:
root # emerge btrfs-progs root # lxc storage create btrfs-1tb-1 btrfs source=/dev/sda4 root # lxc storage set btrfs-1tb-1 btrfs.mount_options compress=lzo
For ZFS, compression should be enabled by default:
root # lxc storage create zfs-1tb-1 zfs source=/dev/sdb
For more control over your storage pool, you can create it first using ZFS, and then add it as follows:
root # zpool create -f lxd-pool /dev/sda /dev/sdb root # zfs set compression=zstd lxd-pool root # lxc storage create lxd-pool zfs source=lxd-pool Storage pool lxd-pool created root #
The above example creates a striped zpool and allows compression to be set explicitly to your preferred setting (there is no easy way I can find to create a striped zpool using the lxc storage create
command directly.)