NFS share displays size of the whole Pool?

Not sure if this is the right forum category but I hope you will move it around if not :blush:

I created a NFS share of 10GB to share ISOs on my VMware server, all fine.
But it shows the full pool size instead of the share size. I tested the share by shrinking and trying to add more then allowed, but that works fine, so it looks more like a cosmetic issue then a bug?

Thanks for reporting this observation @TheRavenKing. I am aware of this behavior, but not sure if there is a way to change it. Perhaps someone with more Linux and NFS experiences than me can let us know if a solution exists. So thanks for starting this topic.

I think the problem is that the share is on the filesystem and the whole drive is ‘included’ I wanted to try the option: no_subtree_check, but can’t test it because when I try to add the option in the export entries [Storage,NFS, Advanced Edit] if gives error.


  • In first instance it complains about my given IP range, when I remove that it comes with following error message:


Got AttributeError when attempting to get a value for field export_str on serializer AdvancedNFSExportSerializer.
The serializer field might be named incorrectly and not match any attribute or key on the list instance.
Original exception text was: ‘list’ object has no attribute ‘export_str’.

Edit: I thought let’s add it manual in the /etc/exports file and to my surprise the option was added.
Although the error message the extra option was there, I use latest version 3.8-3.
More edit: after reboot I checked file again, but this time the no_subtree_check was gone.
Right: I added the option manually, reboot and it was vanished, so I think it is up to you guys now :wink:

@TheRavenKing The attributeerror is a simple bug that I just fixed as part of this issue:, It will be merged into next update along with any other enhancements we want to do with nfs. Thanks for reporting.

regarding no_subtree_check, I think it’s default now(nfs-utils 1.3) as per the exports man page. I have tested it out and adding no_subtree_check has no effect. The size reported is of the whole filsystem and not the individual Share(subvolume).

Once #754 is merged, you’ll get to experiment some more. I’ll update this thread when that happens.

@suman, I found this: using useQuotasInFsStat parameter on NFS shares would show the quota instead of drive space, hope it points you in the right direction, as it looks indeed the issue.


Edit: when looking with df, I notice that my pool is having same size as the NFS share.

/dev/sdb xxxx xxxx 1% /mnt2/poolname
/dev/sdb xxxx xxxx 1% /mnt2/ISO

Hmm, qouta???

# mount | grep /mnt2/ISO
/dev/sdb on /mnt2/ISO type btrfs (rw,relatime,space_cache)

But not the word quota in the options, so it looks like no qouta is enabled, hence we see the full drive size?

# mount | grep '/' | more

I can’t find anywhere qouta enabled, I am lost now, as I don’t know enough about btrfs, your turn :wink:

@TheRavenKing Yes df doesn’t know about btrfs sizes yet, fancy that :smile: hope this is sorted soon as I find it quite disconcerting.

@phillxnet I better try to read up first about btrfs…

you might be able to “hack” it to display what you might expect in terms of free space but the real exact amount of free space cant be calculated properly without knowing the future
see for the explanation (per sub-vol and per file raid levels)

1 Like