Link to home
Start Free TrialLog in
Avatar of atwork2003
atwork2003

asked on

useradd in unix

Hi

I used this command to add user to the group file:

File: /etc/group
Command: useradd -d /home/lsam lsam

It created the user but I dont see the user in the group while nither I can see a home dir created for the user in the path /home/Isam.

I thought I used command incorrectly so I tried to run it again and I get error that user already exists. I am not sure how to find this user and where is the user created. NEED HELP:)
ASKER CERTIFIED SOLUTION
Avatar of yuzh
yuzh

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of atwork2003
atwork2003

ASKER

Thank you for the help. I found the user in the passwd file. But I am not sure why didnt the command created the user directory in the /home directory
>>But I am not sure why didnt the command created the user directory in the /home directory

because you use -d option to tell useradd command to do so.
man useradd
to learn more details.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Great help, thank you so much Guys:) Appreciate it very much