curious about adduser
I am a bit curious about this adding user commands in linux, like adduser and useradd
Just say a user name john1 exists in the system, and then we adduser john1 again, we have an error that shows adduser: The user `john1' already exists. I want to know where the configuration files is placed that shows this message. I want to know how it checks the /etc/passwd file and produce that output. I want to knw teh scripting part of it. Any ideas. Thanks in advance. |
adduser is a shell script, so you can open it with an editor like vi and take a look at its code to see how the various checks are done.
Regards |
issit the adduser.conf???
|
You can use an editor to view adduser as it's a shell script. In Slackware the check is done by this piece of code:
Code:
... I guess that if you have a file called adduser.conf, then it contains the defaults for a user creation, like homedir, shell etc. |
All times are GMT -5. The time now is 10:40 AM. |