Skip to content

Instantly share code, notes, and snippets.

@AkashRajvanshi
Created February 13, 2021 07:50
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AkashRajvanshi/348e6864701bd4023f053b5c31915c5e to your computer and use it in GitHub Desktop.
Save AkashRajvanshi/348e6864701bd4023f053b5c31915c5e to your computer and use it in GitHub Desktop.
# Setup
# List Drives
$ ls /dev/disk/by-id
# Create a pool
$ zpool create -f -m <mount> <pool> <type> <ids>
- create: subcommand to create the pool.
- -f: Force creating the pool to bypass the “EFI label error”.
- -m: The mount point of the pool. If this is not specified, then the pool will be mounted to root as /pool.
- pool: This is the name of the pool.
- type: mirror, raidz, raidz2, raidz3. If omitted, the default type is a stripe or raid 0.
- ids: The names of the drives/partitions to include in the pool obtained from ls /dev/disk/by-id.
# Eg
$ zpool create -f -m /mnt/zstorage zstorage raidz2 <ids>
# To check your pool
$ zpool list
$ zpool list -v
$ zpool iostat
$ zpool iostat -v
# Check Proxmox Storage Manager Know it exists:
$ pvesm zfsscan
# configure your ZFS Pool
$ zfs create zstorage/iso
$ zsf create zstorage/share
$ zsf create zstorage/vmstorage
$ zsf create zstorage/cnstorage
# To set quota
$ zfs set quota=1000G zstorage/iso
# To check
$ zfs list
$ zpool status
$ zpool iostat -v
# Now go to the gui -> Datacenter -> storage -> Add -> Directory -> zstorage/iso ( Make sure only “ISO image” and “Container template” are selected. )
# ...Directory -> Add -> ZFS -> Id: vmstorage -> ZFS Pool: /zstorage/vmstorage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment