zfs rpool/data via commandline / pvesm status fail

tirili

Member
Sep 19, 2018
55
1
8
50
Looking around the installation, we find references to rpool/data. But creating the pool using commandline causes an error....

I did

/sbin/zpool create -f -o ashift=12 rpool mirror /dev/sda4 /dev/sdb4
pvesm add zfspool pve$(hostname -s)-data -pool rpool/data
pvesm set pve$(hostname -s)-data -sparse
pvesm set pve$(hostname -s)-data -content images,rootdir

zpool list gives some info:

# zpool list
NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT
rpool 3.56T 456K 3.56T - 0% 0% 1.00x ONLINE -

# cat /etc/pve/storage.cfg
dir: local
path /var/lib/vz
content rootdir,iso,vztmpl,images
maxfiles 0

zfspool: pvex0720-data
pool rpool/data
content rootdir,images
sparse 1


but pvesm status fails:

# pvesm status
zfs error: cannot open 'rpool/data': dataset does not exist
Name Type Status Total Used Available %
local dir active 1998672 252060 1625372 12.61%
pvex0720-data zfspool inactive 0 0 0 0.00%

How can I get it active?
 
has the rpool a 'data' dataset?
what does zfs list say?
 
Hello Dominik, rpool does not have a data dataset. It was a clean install over debian, and all commands are provided in my post.
I have access to the system this afternoon, then I will provide the zfs list output.
Did I miss a command while creation?
 
if you want to use the data dataset (as in your config -> 'rpool/data') it must exist
you can create it with
zfs create rpool/data
 
Now I have:

# zfs list
NAME USED AVAIL REFER MOUNTPOINT
rpool 348K 3.45T 96K /rpool
# zfs create rpool/data
# zfs list
NAME USED AVAIL REFER MOUNTPOINT
rpool 456K 3.45T 96K /rpool
rpool/data 96K 3.45T 96K /rpool/data

# pvesm status
Name Type Status Total Used Available %
local dir active 1998672 257988 1619444 12.91%
pve-data zfspool active 3705667224 96 3705667128 0.00%


Thank you so much.
Which is the reason/advantage to work with subvolumes like rpool/data, and not directly in rpool ?
 
Which is the reason/advantage to work with subvolumes like rpool/data, and not directly in rpool ?
you can set features/properties of the dataset independent of the rpool (e.g., size limits)
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!