Re: Create user account from putty (Newbie)
- From: catherine@xxxxxxxxxxxxxx
- Date: Mon, 29 Oct 2007 23:22:39 -0700
On Oct 27, 12:25 pm, goarilla <"kevin DOT paulus AT skynet DOT be">
wrote:
cather...@xxxxxxxxxxxxxx wrote:
Hi all, I'm a Linux newbie and I would like to be able to
programatically create a new user account on my VPS.
I'm running CentOs as the operating system and I would like to be able
to create the new account via putty as well as do the following:
Add a new user and specify the users password (The home directory for
this user should also get created). Also, when the account is created
copy over some files from a specified directory and place them in the
newly created home directory.
I have looked on the Internet but I'm a bit confused with all the
flags which are needed and I do not want to do a trial an error
approach. So if someone could please give me an example on how I can
do the above it would be appreciated
Thanks
Catherine
basically you have the useradd (non-interactive) and adduser
(interactive) commands to add users
and don't forget groupadd, gpasswd and usermod ( to manage groups -
noninteractive cmd's ! )
adduser is the simplest it prompts you for some information:
uid, initial group, password, ...
i don't know if adduser abhores it but i don't see no reason why not.
useradd usually copies the contents from 'the skeleton directory' to a
new users' home dir
and sets permissions right, default skeleton dir is usually /etc/skel
also if you are root you can set any users password by doing this
passwd <user>
PS: what's a VPS ? very personal server ?- Hide quoted text -
- Show quoted text -
Thanks everyone
Catherine
.
- References:
- Create user account from putty (Newbie)
- From: catherine
- Create user account from putty (Newbie)
- Prev by Date: Re: Why Vista was designed to suck...
- Next by Date: Re: Looks like the "conspiracy theories" really were true after all...
- Previous by thread: Create user account from putty (Newbie)
- Next by thread: {commercial} SafeSquid 4.2.1 Released
- Index(es):
Relevant Pages
|