Datasheet

Task 1.6: Manage Accounts
29
Scenario
Personnel changes require you to add an account for a new user (Trevor Brown) and delete an
account for an employee who’s leaving (Susan Jones). Changes to the amount of free space on
two disks also requires you to move another user’s (Dale Smith’s) files from the /home2 to the
/home directory tree.
Scope of Task
This task involves creating, deleting, and modifying accounts. Each of these operations is fairly
straightforward, but you must understand the basics of the relevant commands and you must
be aware of the consequences of making mistakes when manipulating user accounts.
Duration
This task should take about half an hour to complete. Once you’re familiar with these tasks,
you can create, delete, or modify accounts in a few seconds to a few minutes, depending upon
the precise operations you need to perform.
Setup
You should log into your Linux system and then use su to acquire superuser privileges. Alterna-
tively, you may log in directly as root, although using su is preferable, as described in Task 1.1.
You may perform this task from a text-mode login or within an xterm window from a GUI login.
For this task, it is assumed that two accounts already exist on the computer—sjones and dsmith.
If your computer lacks these accounts (they aren’t standard), you can create them yourself by fol-
lowing the instructions for creating the first account, but change the usernames.
Caveats
Account maintenance operations are potentially risky. You might accidentally delete or mod-
ify the wrong account. Even account creation poses risks, particularly when you use advanced
options; you might accidentally give two accounts the same user ID (UID) codes, which would
make them essentially interchangeable. Thus, you should be particularly cautious when using
these commands. Because these commands require root access to work, the usual caveats con-
cerning working as root also apply.
This task assumes that you’re working on a Linux system that uses a local account data-
base. Linux systems on LANs often refer to another computer for account management. On
such systems, you would ordinarily modify accounts on the password server system instead of
on the individual workstations and servers.
Procedure
Before delving into account management tools, you should understand the fundamentals of
how Linux manages its passwords. With a basic understanding in hand, you can proceed to
the three parts of this task: adding an account, deleting an account, and modifying an account.
83484.book Page 29 Monday, September 18, 2006 8:58 AM