11.2 iocage jail - freespace of dataset mounts into the jail

Nvious1

Explorer
Joined
Jul 12, 2018
Messages
67
I have a 11.2 iocage jail built and have mounted a dataset into the jail
iocage fstab -a jailName /mnt/pool/dataset /mymount nullfs rw 0 0

Is there any good way inside the jail to get a freespace amount of a mount?

Am I making this more complicated than it is and should I just let the jailed application use up space inside the jail? I went with the mount so that in the future I could access the data the jail is storing via CIFS via the mounted dataset, but I can probably deal with not having that.
 

garm

Wizard
Joined
Aug 19, 2017
Messages
1,556
A dataset has access to the entire available space of a pool, unless you set a quota for it. Why do you need to see the free space from the jail? You can just monitor the space available in the pool from FreeNAS?
 

Nvious1

Explorer
Joined
Jul 12, 2018
Messages
67
I plan to run an ftp server that has a free space monitoring script. Once the space gets to a certain percentage of used it will clear out out stuff based on age. Since I am writing the data to a different dataset than what the root system of the jail is in, the free space checker only knows how to look at what the jail os can provide which only includes its operating dataset.

Maybe I could cheat by nfs mounting the same dataset as read-only to monitor the space but do all my rights by the nullfs mount.
 
Top