Previous Table of Contents Next


Setting Up a User's Mail Account

Each user has a mailbox either on a local system or on a mail server and a mail alias in the /etc/mail/aliases file that points to the location of the mailbox. To set up a mail client with a mailbox on a mail server:

1.  Become superuser on the mail client's system.
2.  Create a /var/mail mount point on the mail client's system.
3.  Edit the /etc/vfstab file and add an entry for the /var/mail directory on the mail server, mounting it on the local /var/mail directory. The client's mailbox will automatically be mounted any time the system is rebooted.
4.  Type mount -a to mount the mailbox. The client's mailbox is mounted.
5.  Use Admintool to edit the /etc/hosts file and add an entry for the mail server.


NOTE:  The sendmail program automatically creates mailboxes in the /var/mail directory the first time a message is delivered. You do not need to create individual mailboxes for your mail clients.

If you are using NIS+, follow these steps to set up mail aliases for the user:

1.  Compile a list of each of your mail t clients, the locations of their mailboxes, and the names of the mail server systems.
2.  Become superuser on any system.
3.  For each alias, type aliasadm -a alias expanded-alias[options comments] and press Return. The alias is added to the NIS+ aliases table. For example, adding an alias for user iggy.ignatz would look like this:
# aliasadm -a iggy iggy.ignatz@oak "Iggy Ignatz"
4.  Type aliasadm -m alias and press Return. The entry you created is displayed.
5.  Check the entry to be sure it is correct.

Setting Up a User's Printer

After adding users to a system, make sure they have access to a printer. See Chapter 6, "Administering Printing," for information on how to set up printing services.

Creating a Password

Passwords are an important part of system security. Each user account should be assigned a password of 6 to 10 characters using a combination of letters and numbers. See the passwd(1), yppasswd(1), or nispasswd(1) manual pages for information about changing passwords and password attributes.

In the SunOS 4.x system, encrypted passwords are stored in the /etc /passwd file along with the rest of the information about the user. In SunOS 5.x, the encrypted password and associated password aging information are stored in the Shadow field of the NIS+ Passwd database (or in the local /etc /shadow file). Permissions on the Shadow field are restricted. Permissions for the /etc/shadow file are -r--------. Only root can read the /etc/shadow file, and only the passwd, yppasswd, and nispasswd commands can write to the file.

Here is an example of an /etc/shadow file:

root:XzVuae1vazZsw:8223::::::
daemon:NP:6445::::::
bin:NP:6445::::::
sys:NP:6445::::::
adm:NP:6445::::::
lp:NP:6445::::::
smtp:NP:6445::::::
uucp:NP:6445::::::
nuucp:NP:6445::::::
listen:*LK*:::::::
nobody:NP:6445::::::
noaccess:NP:6445::::::
nobody4:NP:6445::::::
winsor:gzqgrmlKcfy7A:8223::::::

To create or modify passwords, use one of these commands:

  /usr/bin/passwd (for no naming service)
  /usr/bin/nispasswd (for the NIS+ naming service)
  /usr/bin/yppasswd (for the NIS naming service)

Users can create or change their own passwords at any time. You must be root to create the initial password for any other user. In addition, to create an NIS+ password, you must have the appropriate NIS+ privileges and you must have established the necessary networkwide credentials. (See the nispasswd(1) manual page.)

Follow these steps to create an NIS+ password:

1.  Become superuser on the NIS+ server.
2.  Type nispasswd login-name and press Return. The message New NIS+ password: is displayed.
3.  Type the new password and press Return. The prompt Retype new NIS+ password: is displayed.
4.  Retype the password and press Return. The password is assigned and added to the NIS+ database.

In this example, a new password is assigned for the user ignatz:

oak% su
Password:
# nispasswd ignatz
New NIS+ password:
Retype new NIS+ password:
#

Follow these steps to change an NIS+ password:

1.  Become superuser on the NIS+ server.
2.  Type nispasswd login-name and press Return. The prompt Old password: is displayed.
3.  Type the old password and press Return. The prompt New password: is displayed.
4.  Type the new password and press Return. The prompt Re-enter new password: is displayed.
5.  Retype the password and press Return. The password is assigned and added to the /etc/shadow file.

In this example, the password for user ignatz is changed:

oak% su
Password:
# nispasswd ignatz
Old password:
New password:
Re-enter new password:
#


NOTE:  You can also use nispasswd to define, change, and view password attributes, such as password aging. See the nispasswd(1) manual page for more information.

Follow these steps to create an NIS password:

1.  Become superuser on any system in the NIS domain.
2.  Type yppasswd login-name and press Return. The message Changing NIS password for login-name and the prompt New password: are displayed.
3.  Type the new password and press Return. The prompt Retype new password: is displayed.
4.  Retype the password and press Return. The password is assigned and added to the NIS master file.

In this example, the NIS password is changed for user yaya:

oak% su
Password:
# yppasswd yaya
Changing NIS password for yaya
New password:
Retype new password:
NIS entry changed on eucalyptus
#

Changing an NIS password is similar to changing an NIS+ password. When prompted to do so, type the old password, and then the new password two times.


Previous Table of Contents Next