You are not logged in.
Pages: 1
Hey. I was just trying to create a user using useradd, but it always returns invalid username 'username'. I searched a lot but couldn't find anything on it other than not allowing dot in username which I wasn't using anyway. Any way to fix this?
Last edited by Zayed_ (2019-07-27 06:59:21)
"Never give up!" - Anonymous
Offline
Please post the full command you used and its output.
Offline
Please post the full command you used and its output.
useradd -m LinuxUser
useradd: invalid username 'LinuxUser'
"Never give up!" - Anonymous
Offline
Please see the CAVEATS sections of man 8 useradd.
Offline
I searched a lot but couldn't find anything on it other than not allowing dot in username ...
I just tried several variations on 'valid linux username' and 'legal linux username' and all of them produce the same rule as is elaborated in the manual page as the very first result. One should search before asking here, but I think it's slightly less off to simply neglect to search than to claim you did when you clearly did not.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Zayed_ wrote:I searched a lot but couldn't find anything on it other than not allowing dot in username ...
I just tried several variations on 'valid linux username' and 'legal linux username' and all of them produce the same rule as is elaborated in the manual page as the very first result. One should search before asking here, but I think it's slightly less off to simply neglect to search than to claim you did when you clearly did not.
Damn. I'm really sorry. Didn't check properly, I guess? How do I close/delete the thread?
"Never give up!" - Anonymous
Offline
Either edit your initial post and change the subject (prepend "[SOLVED]") or report the original post for deletion. Links are on the bottom of the post.
Offline
Please don't delete the thread. You have learned something from it, so maybe one day someone else will as well. Just mark it as SOLVED.
Last edited by twelveeighty (2019-07-26 13:44:33)
Offline
Pages: 1