此内容没有您所选择的语言版本。
32.2.5. Explaining the Process
				The following steps illustrate what happens if the command 
useradd juan is issued on a system that has shadow passwords enabled:
			- A new line forjuanis created in/etc/passwd. The line has the following characteristics:- It begins with the usernamejuan.
- There is anxfor the password field indicating that the system is using shadow passwords.
- A UID greater than 499 is created. (Under Red Hat Enterprise Linux, UIDs and GIDs below 500 are reserved for system use.)
- A GID greater than 499 is created.
- The optional GECOS information is left blank.
- The home directory forjuanis set to/home/juan/.
- The default shell is set to/bin/bash.
 
- A new line forjuanis created in/etc/shadow. The line has the following characteristics:- It begins with the usernamejuan.
- Two exclamation points (!!) appear in the password field of the/etc/shadowfile, which locks the account.Note If an encrypted password is passed using the-pflag, it is placed in the/etc/shadowfile on the new line for the user.
- The password is set to never expire.
 
- A new line for a group namedjuanis created in/etc/group. A group with the same name as a user is called a user private group. For more information on user private groups, refer to Section 32.1.1, “Adding a New User”.The line created in/etc/grouphas the following characteristics:- It begins with the group namejuan.
- Anxappears in the password field indicating that the system is using shadow group passwords.
- The GID matches the one listed for userjuanin/etc/passwd.
 
- A new line for a group namedjuanis created in/etc/gshadow. The line has the following characteristics:- It begins with the group namejuan.
- An exclamation point (!) appears in the password field of the/etc/gshadowfile, which locks the group.
- All other fields are blank.
 
- A directory for userjuanis created in the/home/directory. This directory is owned by userjuanand groupjuan. However, it has read, write, and execute privileges only for the userjuan. All other permissions are denied.
- The files within the/etc/skel/directory (which contain default user settings) are copied into the new/home/juan/directory.
				At this point, a locked account called 
juan exists on the system. To activate it, the administrator must next assign a password to the account using the passwd command and, optionally, set password aging guidelines.