[Ubuntu 16.04.7, ISPConfig, Jailkit]
I needed to change the UID of a newly created (jailed) user (via ISPConfig's Add Shell User function) to disambiguate from other users on the same virtual host. So I determined the next available uid and performed usermod -u xxxx UserName.
I checked the user's home directory and instead of the username showing in the user column, the uid was showing. At first I didn't think much of this result.
When I logged in as the new user, I found that, whilst everything else was working the prompt had the username was set to I have no name!. Since I didn't need/want to change the username (and did not), I was surprised by this outcome. When I performed id for this user, I got (note the user's name is not shown next to their uid):
uid=5016 gid=5007(groupName) groups=5007(groupName)
The user is definately in the /etc/passwd file.
After searching all over the place, I have not found anything that has resolved this problem. How can I fix this?
usermoddoes not change the uid on the user's files, so the files' owner has to be changed withchown.passwdinside the jail that I missed. If you outline how to do that, I'll mark it as the correct answer. I manually edited the<jail>/etc/passwdfile manually.