dscacheutil -h
-q category [-a key value]
-cachedump [-buckets] [-entries [category]]
-configuration -flushcache -statistics
Does operations against the Directory Service cache including gathering statistics, initiating lookups, inspection, cache flush, etc
-q category |
categories and associated keys:
group name or gid
|
% dscacheutil -q user -a name jdoe name: jdoe password: ******** uid: 501 gid: 501 dir: /Users/jdoe shell: /bin/csh gecos: John Doesee
/etc/passwd
or
Seems to contain 2 entries for all "original" users although only one is displayed by
dscacheutil -q user -a name uname
dscacheutil -q user |grep -n ' root' 633:name: root 817:name: root dscacheutil -q user |grep -n ' Guest' 345:name: GuestLookup all users: (reformatted)
% dscacheutil -q user name: _amavisd password: * uid: 83 gid: 83 dir: /var/virusmails shell: /usr/bin/false gecos: AMaViS Daemon name: _appleevents password: * uid: 55 gid: 55 dir: /var/empty shell: /usr/bin/false gecos: AppleEvents Daemon name: _applepay password: * uid: 260 gid: 260 dir: /var/db/applepay shell: /usr/bin/false gecos: applepay Account name: _appowner password: * uid: 87 gid: 87 dir: /var/empty shell: /usr/bin/false gecos: Application Owner name: _appserver password: * uid: 79 gid: 79 dir: /var/empty shell: /usr/bin/false gecos: Application Server name: _ard password: * uid: 67 gid: 67 dir: /var/empty shell: /usr/bin/false gecos: Apple Remote Desktop name: _assetcache password: * uid: 235 gid: 235 dir: /var/empty shell: /usr/bin/false gecos: Asset Cache Service … name: _applepay password: * uid: 260 gid: 260 dir: /var/db/applepay shell: /usr/bin/false gecos: applepay Account name: _hidd password: * uid: 261 gid: 261 dir: /var/empty shell: /usr/bin/false gecos: HID Service UserDump cache overview:
% dscacheutil -cachedumpDump cache details with user entries:
% dscacheutil -cachedump -entries user
dsmemberutil [-v] [-h] command [options]
implements the membership API calls in a command line utility.
-h help -v verbose getuuid -ugUGsS value Takes any of the options and returns the associated UUID. getid -UGsSX value Takes any of the options and returns the associated UID or GID depending on option provided. getsid -ugUGX value Takes any of the options and returns the associated SID. checkmembership -uUxs param -gGXS param Returns if a user or group with the associated option is a member of the group. flushcache In some cases -xX and -sS can be used synonymously due to nature of the value. Using user -u uid -U name -s sid -x uuid Using group -g gid -G name -S sid EXAMPLES Get a user's uuid: % dsmemberutil getuuid -u 501 EEA4F2F6-B268-49E7-9C6F-E3C4A37DA4FD Get a group's uuid % dsmemberutil getuuid -g 0 ABCDEFAB-CDEF-ABCD-EFAB-CDEF00000000 Get a user's or group's id from a uuid % dsmemberutil getid -X ABCDEFAB-CDEF-ABCD-EFAB-CDEF0000000C gid: 12 Check a user's membership in a group (using UID and GID) % dsmemberutil checkmembership -u 501 -g 0 user is not a member of the group Check a user's membership in a group (using names) % dsmemberutil checkmembership -U root -G wheel user is a member of the group . See odutil(1) for show cache and statistics operations.SEE ALSO odutil(1), dseditgroup(1), dscacheutil(1)
Unable to get details from the cache node