Introduction to/etc/passwd and/etc/shadow file formats in Linux

Source: Internet
Author: User
In Linux, the/etc/passwd and/etc/shadow file formats are described as follows. comroot: x: 0: 0: root:/bin/bashbin: x: 1: 1: bin:/sbin/nologindaemon :... in Linux, the/etc/passwd and/etc/shadow file formats/etc/passwd are used to store users. the content is as follows: www.2cto.com root: x: 0: 0: root: /root:/bin/bashbin: x: 1: 1: bin:/sbin/nologindaemon: x: 2: daemon:/sbin/nologinadm: x: 3: 4: adm:/var/adm:/sbin/nologinlp: x: 4: 7: lp:/var/spool/lpd :/ Sbin/nologinsync: x: 5: 0: sync:/sbin:/bin/syncshutdown: x: 6: 0: shutdown:/sbin/shutdownhalt: x: 7: 0: halt:/sbin/haltmail: x: 8: 12: mail:/var/spool/mail:/sbin/nologin format: user name: Password: uid: gid: User description: main directory: login shell UID: each user must be assigned a userid, "0" is the root retention ID. 1-99 is reserved for the system and assigned to the system's pre-defined account. HP-UX10.20 support 2 147 483 646. the HP-UX10.20 previously supported no more than 60000. in the www.2cto.com system, a type of users are called psuedo users. these users also have a record in the/etc/passwd file, but cannot log on because of their logon. Shell is empty. They are mainly used to facilitate system management and meet the file owner requirements of the corresponding system processes. Common pseudo users are shown in Table 8-1. Table 8-1 common pseudo-user in/etc/passwd files the meaning bin has the executable user command file sys owns the system file adm owns the account file uucpUUCP uses lplp or lpd the subsystem uses nobodyNFS in addition to the pseudo Outdoor Systems listed above, there are also many standard pseudo users, such as audit, cron, mail, and usenet, which are also required by related processes and files. The record lines in/etc/shadow correspond one to one with those in/etc/passwd. it is automatically generated by the pwconv command based on the data in/etc/passwd. Its file format is similar to/etc/passwd and consists of several fields separated. These fields are: login name: Encrypted password: last Modification time: Minimum Interval: maximum interval: Warning Time: inactive time:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.