Root on ZFS - is it normal to not have a (ZFS) cachefile defined for the rpool?

ZPrime

New Member
Apr 29, 2021
12
5
3
43
Cleveland, Ohio, USA
My system is just a single node, running with a pair of SSDs in a ZFS mirror. It was setup as 100% ZFS using the Proxmox installer.

I wanted to run zdb to check on some info about the pool (specifically I was curious about the ashift / block size setting).

zdb comes back with this error:
cannot open '/etc/zfs/zpool.cache': No such file or directory

Now, I'm kind of thinking this might be expected behavior - presumably with root on ZFS, we're booting from a temporary ramdisk, and i don't know how it'd be possible to read in a cachefile from that scenario?

Or is there some way to set the cachefile and make everything work nicely... and if so, why wasn't this done by the installer?
 
Last edited:
you don't need a cache file for zdb to work - which command did you want to run?

a cache file mainly makes sense on systems with lots of (possibly irrelevant) storage attached, as without it, the system will scan *all block devices* on bootup, importing any found zpools, which can take a while ;)
 
I wanted to run zdb -C against the rpool. Eventually I found the -e flag which makes it work... I just found it odd that there was no cachefile configured by default.
 
Hey @ZPrime, would you mind sharing an example of the command(s) that works for you? :)
I have a couple pools and only one is recognized by zdb. Idk why. The pools were created with different versions of zfs but I don't see a clear reason.
 

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!