Univention Bugzilla – Bug 48000
Quota policies are overwritten with 0/0/0/0 if there's at least one share without quota policy reference
Last modified: 2019-07-10 13:20:30 CEST
Cloning to track this separately. Quota policies are currently always overwritten if there's at least one share without a reference to it. This is especially problematic in school environments where a share is created for every single class, quickly resulting in a LOT of shares. The problem seems to be that univention-user-quota doesn't process a share without a reference to a quota policy as "no quota" but as "0/0/0/0". Since 0 is smaller than any configured quota, it always overwrites other quota policies, because it is always the most restrictive quota. Workarounds: - Apply a reference to the quota policy on a container above the shares in the LDAP tree (e.g. the school OU) (the LDAP directory module can be used for this) - Apply a reference to the quota policy to every existing share +++ This bug was initially created as a clone of Bug #40001 +++ The checkbox "Reapply settings on every login" does not overwrite user specific quota on login. In the UMC module the soft and hard limit for Data size shows 0/0 but the user specific quota is still valid.
Will probably affect a lot of school environments, quotas are a very regular requirement there in my experience. -> key scenario
There is a fix available in branch jahlers/48000-quota-0/0/0/0.
To fix this bug, I refactored a whole lot of the univention-user-quota script. It should work as intended now, 0 will not be interpreted as the smallest value anymore. I also wrote some tests for multiple quota policies that are defined on shares that are on the same mountpoint. 76173d2a97 Bug #48000: yaml 64d56a6ffe Bug #48000: Merge branch 'jahlers/48000-quota-0/0/0/0' into 4.4-0 a51a0300c5 Bug #48000: yaml 96dc639414 Bug #48000: make changes after code review 70b881130c Bug #48000: make quota behave better when two shares with quota policies are on the same mountpoint ed4e381c8e Bug #48000: added new tests for quota dd79fbcfa3 Bug #48000: fix typo 9405a2614c Bug #48000: refactoring of quota script Successful build Package: univention-quota Version: 13.0.1-5A~4.4.0.201907081649 Branch: ucs_4.4-0 Scope: errata4.4-0 Successful build Package: ucs-test Version: 9.0.2-117A~4.4.0.201907081705 Branch: ucs_4.4-0 Scope: errata4.4-0
What I tested: Merge -> OK Policy without "reapply each login" -> quota is set for user without quota -> OK Policy without "reapply each login" -> quota is not set for user with quota -> OK Policy with "reapply each login" -> quota is set for user without quota -> OK Policy with "reapply each login" -> quota is set for user with quota -> OK Policy mixing -> smallest values are chosen for each attribute, EXCLUDING zero values -> OK Tests -> OK Small yaml change to make it more clear what the fixed bahaviour is: [4.4-0 a782f63dab] Bug #48000: yaml -> Verified
<http://errata.software-univention.de/ucs/4.4/180.html>