On XFS filesystem, quota accounting can be enabled without enforcing quota. That is, usage is recorded for each user, quota soft/hard limit can be configured for each user or group, but no actual enforcement occurs when trying to exceed quota. In that case, the "free disk" reporting must not take quota into account because quota would not limit disk usage. However, Samba clamps the free disk with the user's configured quota values. The desired behavior: I verified (by experimentation) that: 1. NTFS has a similar notion of separately turning on accounting and enforcement. 2. On a Windows server, getting/setting user quota can be done even if enforcement is off - getting quota (e.g. by smbcquotas) returns the configured value even if quota is not enforcing 3. OTOH, disk size and free space is not clamped by quota if no enforcement takes place. This means that for XFS, smbcquotas is not affected by whether the system is enforcing or not, but smbclient free-disk printout is affected.
Created attachment 12142 [details] git-am fix for 4.4.next
Comment on attachment 12142 [details] git-am fix for 4.4.next LGTM.
Re-assigning to Karolin for inclusion in 4.4.next.
(In reply to Jeremy Allison from comment #3) Pushed to autobuild-v4-4-test.
(In reply to Karolin Seeger from comment #4) Pushed to v4-4-test. Closing out bug report. Thanks!