Open System Services Shell and Utilities Reference Manual (G06.29+, H06.08+, J06.03+)

Administrator Commands and Files usermod(8)
NAME
usermod - Modifies a user account.
SYNOPSIS
usermod [OPTION] LOGIN
usermod -A ALIAS_NAME [OPTION]
FLAGS
The following flags are only valid on systems running Safeguard. If these flags are used on a sys-
tem not running Safeguard, a diagnostic message is reported on STDERR and the command exits
with the exit status of 15.
-A ALIAS_NAME
Modify user alias with name ALIAS_NAME.
-c COMMENT
Any text string of 80 characters maximum length. Generally a short description of the login.
Currently used as the field for the user’s full name.
-d HOME_DIR
The user’s new login directory. If the -m option is given, the contents of the current home
directory are moved to the new home directory, which is created if it does not already exist.
-e EXPIRE_DATE
The date on which the user account will expire. The date is specified in the format
"YYYY-MM-DD".
-f INACTIVE
The number of days after a password expires until the account is expired. This value ranges
from 0 through 32767. A value of 0 disables the account when the password expires, unless
the PASSWORD-EXPIRY-GRACE attribute in the Safeguard configuration record
specifies a different value.
-L Locks or freezes the user account and temporarily suspends the users ability to log on to a
system. You cannot use this option with -p or -U.
-m Move the content of the users home directory to the new location. This option is only valid
in combination with the -d option.
-p PASSWORD
The password.
-U Unlock or thaw a users account. You cannot use this option with -p or -L.
The following flag is always valid.
-h Display this help and exit.
DESCRIPTION
The usermod command modifies the system account files to reflect the changes that are specified
on the command line.
You can specify the LOGIN name in a fully qualified form
groupName.memberName:groupNum,memberNum’ (no white spaces); or a partial name contain-
ing only the memberName. When a partial name is used, the group name and corresponding group
number is taken from the GROUP variable in the /etc/default/users file.
In the usermod -A ALIAS_NAME [OPTION] form, a user alias is modified.
NOTES
527188-021 Hewlett-Packard Company 1277