Hi,
recently I noticed, that we do have a problem with quota on some accounts.
Our students have nummeric usernames like 010203 and there accounts are generated "semiautomatically" by using the scriptfunktion of webmin.
Now a "repqouta -a" shows the current usage, but some accounts have compleatly different values if I try to change their quota with edquota.
e.g. the user with the name "0106322" anmd the ID 1093 from /etc/passwd looks like this:
repquota: 0106322 +- 101204 81920 163840 none 1 0 0
edquota: Disk quotas for user 0106322 (uid 36050): Filesystem blocks soft hard inodes soft hard /dev/sda6 0 0 0 0 0 0
The strange thing is, that I do have users whith the right UID in ther quota settings and a nummeric username.
Any ideas, hints or tricks? What could be the problem and better, how to solve this?
Thanks and best regards
Götz Reinicke
Götz Reinicke wrote:
recently I noticed, that we do have a problem with quota on some accounts.
Our students have nummeric usernames like 010203 and there accounts are generated "semiautomatically" by using the scriptfunktion of webmin.
As you've probably spotted by now, Unix has problems with all-numeric usernames. Many programs will accept either a username or an (also numeric) user-ID as a way of identifying a user. If you have a username that is the same as a user-id, you can't be sure which user the command will think you meant.
To add to the problem, leading zeros often mean "this number is octal", so 010203 may not be the number you think it is.
The real solution, unfortunately, is not to have all-numeric usernames.
James.