Linux command: ID

Source: Internet
Author: User

ID Introduction to Commands:

This command is used to view the user's account attribute information

1 . command format:

ID [option] USERNAME

2 . Command function:

used to view the attribute information for a user account that already exists on the system.

[[email protected] test1]# ID Tom

uid=666 (Tom) gid=666 (Tom) group =666 (Tom), (Donggen)

3. Command parameters:

- u View only the user's ID number uid

- G View only the user's group ID number GID

- G View only the user's additional group ID number GID

- N Viewing user information is displayed as a name and is not displayed with an ID number and is used with-u-g-G.


4. Command instance:

1, id-u Tom Display user Tom's UID number

[Email protected] test1]# id-u Tom

666

2, id-g Tom Display user Tom's GID number

[Email protected] test1]# id-g Tom

666

3, id-g Tom Display user Tom's GID number (additional group number)

[Email protected] test1]# id-g Tom

666 500 The default attachment group must have one base group and other attachment groups.

4. ID-G-N Tom displays user Tom's GID number (additional group number) and displays it by name

[Email protected] test1]# id-g-N Tom

Tom Donggen

5.

This article is from the "Learn Linux history" blog, please be sure to keep this source http://woyaoxuelinux.blog.51cto.com/5663865/1861065

Linux command: ID

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.