Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding new user to system

Status
Not open for further replies.

zum

Technical User
Mar 31, 2003
148
US
I'm running SUNOS 5.8. I'm a newbie. What is the correct way to add a new user to the system?

Thanks,
 
The easiest way to add a local user is to use admintool.
You will first need to know some information.
1. User Name
2. User ID Number
3. Group ID Number
4. Default Shell (sh, ksh, csh)
5. Home Directory Location.

UserName: Just about anything would work... Normally 4 to 8 characters long. At work, I use First Initial and and up to the first 7 characters of the last name.

User ID: Unique number for users. Normally starts at 1001

Group ID: Unique number. There are some numbers already declared. You can see them in the file /etc/group. You may want to create a group for your local users. I created group 15 users for my local users. You can use admintool to do this or edit the file /etc/group. Make sure you follow the syntax of the default groups.

Default Shell: There are several default shells. For most users, the csh or tcsh is the easiest to use.

Home Directory Location: This really depends on how your workstation is set up. I place all my users in a directory /export/home/<username>.

To use admintool to do this:

Login as root
Open a terminal window and enter: admintool &

If you want to create a group 15, select:
Browse--->Groups
Edit--->Add
Group Name: users
Group ID: 15
There is no reason to put any names. This will be the primary group for your users.
Select OK

To add a user select:
Browse--->Users
Edit--->Add
Enter username - normally all in lower case
Enter userid
Enter Comments - Normally contains Users Real Name/phone number, etc.
Select Shell: Bourne, Korn C
Select Password: More than 6 alphanumeric characters. I use the users login name as a starting password. Once they login for the first time, I have them run the command "passwd" to change their passwords.
Make sure "Create Home Dir" is selected. By default it is.
Enter the path for the users home directory: Example - /export/home/<username>


Hope this helps... If you have any questions, let me know.

If you really want to know what admintool is doing, you can look at "man useradd". Everything admintool is doing can be done via command line using command "useradd
 
Oops... I forgot primary group. If you created group 15, enter 15 in this box. Secondary group, you can leave blank for now.
 
Also man useradd for the real Sys Admin's way of doing it (or mucking it up depending on your viewpoint!) ;-)
 
Ah thanks. I'll try this. This is a little different from HP-UX.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top