2019-02-24 15:47:41 +00:00
|
|
|
# getent
|
2016-02-19 23:09:38 +00:00
|
|
|
|
|
|
|
> Get entries from Name Service Switch libraries.
|
2021-07-09 15:45:55 +01:00
|
|
|
> More information: <https://manned.org/getent>.
|
2016-02-19 23:09:38 +00:00
|
|
|
|
|
|
|
- Get list of all groups:
|
|
|
|
|
|
|
|
`getent group`
|
|
|
|
|
|
|
|
- See the members of a group:
|
|
|
|
|
2018-12-04 21:16:17 +00:00
|
|
|
`getent group {{group_name}}`
|
2016-02-19 23:09:38 +00:00
|
|
|
|
|
|
|
- Get list of all services:
|
|
|
|
|
|
|
|
`getent services`
|
|
|
|
|
|
|
|
- Find a username by UID:
|
|
|
|
|
|
|
|
`getent passwd 1000`
|
|
|
|
|
|
|
|
- Perform a reverse DNS lookup:
|
|
|
|
|
|
|
|
`getent hosts {{host}}`
|