Cant edit users
joelt last edited by
Sometimes if i create a user, change the name for that user, then try to go back to the original username it says the following:
"That username is reserved by the system"
I dont know why it only does this for some users but how can i go back to the original username when i get this error?
I do see the username in /etc/passwd. Do i delete that? If so, how?
Gertjan last edited by
I can reproduce this issue.
I have a user, "001", Full name "001" - with password, member of a group called PortalUsers.
This is a non "root" user, just a login for my captive portal.
I could edit it, changing username and full name to "001001 and "001001" and identical password.
Save => Ok.
I wanted to re edit this user to go back to "001" for username and Full name : the error was shown.
Of course, a user called "001001" or "001" can't be "reserved by the system" ....
So trying to reproduce this - created user billy, changed it to billyuser, then back to billy without any issues.
Ok I even created a group.. Put billy in the group, then changed his name to billytest2, then back to billy
Can not reproduce this - you have maybe something filling in the info for you in your browser like admin.. Lastpass could do this - I logged out of lastpass while testing this because it kept putting in admin for the username when hit the edit billy button.
Gertjan last edited by Gertjan
Was about to edit my post but @johnpoz was to fast.
Again, I took a user "001", etc etc see my image above.
So, I checked the manual (/usr/local/www/systemuser_manager.php and /etc/inc/auth.inc where the function local_user_set() lives) and put this function in debug mode (adding $debug=1; at the start of the function).
Logging should became more verbose.
Then, I did the thing one shouldn't do, I edited (deleted the line) the user "001001:*:2057:65534:002:/home/001:/sbin/nologin in /etc/passwd.
(and removed /home/001001/ also).
From there on : I had more vebose logs ***, no more problems. I could edit - and edit again - re-edit, delete, create, edit.
I removed the debug line.
Still, all ok, the error vanished.
I have this feeling that I touched the /etc/passwd file (system == FreeBSD maintained) and after that all was ok again.
I can't explain ....
** more verbose logs in the ....... captive portal log - not the system log ...
edit : I rebooted. Could edit a user just fine.
Strange - but solved