- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: useradd
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 03:43 AM
тАО07-09-2009 03:43 AM
i want to create 5 users at a time means using single command i want to create 5 users.
plz help me on this
regards,
himacs
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 03:48 AM
тАО07-09-2009 03:48 AM
Re: useradd
I posted a simple script that reads its input from a file just yesterday in this thread:
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1353860
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 03:58 AM
тАО07-09-2009 03:58 AM
Re: useradd
Useradd command takes single login input by default. You can use for loop like this..
for USER in user1 user2 user3 user4 user5
do
useradd -m $USER
done
This will create the users with default shell, default group. If you want specific shell, specific group or specific command, you can pass the informations to the useradd command.
useradd -g
Ganesh.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 04:10 AM
тАО07-09-2009 04:10 AM
Re: useradd
thanx for ur reply..it was useful.
plz let me know any option with useradd command to create multiple users at a time,without using script.
regards,
himacs
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 04:20 AM
тАО07-09-2009 04:20 AM
Re: useradd
> plz let me know any option with useradd command to create multiple users at a time, without using script.
Define "script". If I write more than one command on the command line is that considered a script or not? If the multiple commands and operators don't easily fit in (for example) an 80-character command line and I then put them into a file for repeated use and/or maintainability, that's generally called a "script".
Why are you so concerned here?
With regard to 'useradd' the anwser to your question is "no".
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 04:45 AM
тАО07-09-2009 04:45 AM
Re: useradd
thanks
let me use script for the same..
regards
himacs
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-09-2009 05:16 AM
тАО07-09-2009 05:16 AM
Solution>>>plz let me know any option with useradd command to create multiple users at a time,without using script.<<<
This I have answered in my previous reply. useradd command will not accept more than one username as arguments. You can check the man page.
Ganesh.