Univention Bugzilla – Bug 54638
Filesystem quota doesn't work with usernames containing only numbers [5.0]
Last modified: 2022-05-04 16:58:47 CEST
We also need this in UCS 5.0 +++ This bug was initially created as a clone of Bug #54537 +++
cherry-pick from 4.4-9: ad0e1dee8f | Make quota work for numeric only usernames e6f479fe10 | Advisory version Package: univention-quota Version: 14.0.1-10A~5.0.0.202204201908 Branch: ucs_5.0-0 Scope: errata5.0-1
REOPEN: while the code changes look good there seems to be another problem. When I add a user "1234" assign a file limit of 33/34 and size limit of 2mb/3mb and reach the limits then the quotas are removed. su 1234 for ((i=1;i<=10; i++)); do dd if=/dev/urandom of=foo$i count=1024 done
Created attachment 10941 [details] umc-quota-numeric-username.png Cannot reproduce in UCS 5.0-1: * Created user named "5678" and configured quota explicitly for that user * Ran the above loop and obtained: dm-0: write failed, user block limit reached. dd: Schreiben in 'foo6': Der zugewiesene Plattenplatz (Quota) ist überschritten etc. * Looked into UMC and quota disaplay looks as expected, see attached screenshot.
Ok, could reproduce: After creating a file share a simple `su - 1234` removes the quota. Debugging with `ucr set quota/logfile=/tmp/1.log` showed that univention-user-quota calls setquota with `0 0 0 0`. That was caused because the preceeding call to quota was still missing the --always-resolve. 02c043f6d1 | Advisory update 14dce0c2cc | Add missing --always-resolve to univention-user-quota
OK: quotas work for users with numeric only usernames OK: YAML
<https://errata.software-univention.de/#/?erratum=5.0x299>