1753726 Members
4888 Online
108799 Solutions
New Discussion юеВ

user creation

 
gany59
Regular Advisor

user creation

i need to create 10 users with the same privilages.. for this may i know the command and script.Could any body tell this.I am new to hp-ux.. Thanks in advance.. 10 points assured..
8 REPLIES 8
Mel Burslan
Honored Contributor

Re: user creation

for uname in john mike roger etc # add all usernames before "#" sign
do

useradd -m $user

done
________________________________
UNIX because I majored in cryptology...
Michael Steele_2
Honored Contributor

Re: user creation

Hi:

http://docs.hp.com/en/B2355-90692/useradd.1M.html

a) Track a list of unique UID's.

For example:

useradd -u ###1 -g users -d /home/login_account -s sh -c User_name, Phone #, Dept, else login_account

For 2nd user:

useradd -u ###2 -g users -d /home/login_account -s sh -c User_name, Phone #, Dept, else login_account

Support Fatherhood - Stop Family Law
James R. Ferguson
Acclaimed Contributor

Re: user creation

Hi:

You have asked no less then eleven (11) basic questions today. In one of your threads you said, "see actually this was the question asked to me in interview. so i am very eager to know those things."

My answer to that is READ and experiment on a test system! Besides manpages there is a tremendous, free library here:

http://www.docs.hp.com

...JRF...

Michael Steele_2
Honored Contributor

Re: user creation

Oh Geeez;

You're new to unix and going for an interview and can't find these answers on your own? You don't even really give out any points? (* 10 of 38 *)

Well, I'm sure they'll hire you. All they ask now-a-days is - "...Do you have ten fingers and can you count to 10...?" I'm sure if you say:

"..Uno, dos, tres....", you'll be hired.

See you living on the forum for awhile, just remember to give points.
Support Fatherhood - Stop Family Law
gany59
Regular Advisor

Re: user creation

hey micheal
mind ur words..if u r not willing to answer my question,nothing can cause me.so dont do like this
Fabian Brise├▒o
Esteemed Contributor

Re: user creation

ouch.
Boys play nice.

Gany the guys here do have a point, you have been asking very basic questions, questions that can be answered by using the man pages or by doing a simple online search here in the forums.

My two cents.


Have a nice day.
Knowledge is power.
Jitesh purohit_1
Regular Advisor

Re: user creation

You can download the Puttycs tool, It's purpose is to send the same command to each PuTTY window.

http://www.millardsoftware.com/puttycs

Thanks
Jitesh
Suraj K Sankari
Honored Contributor

Re: user creation

Hi,
add all 10 user name into a file suppose /tmp/abc.txt
now give this command at command prompt
for i in `cat /tmp/abc.txt`
do
adduser $i
done

Suraj