|
|
HP-UX Reference > Nnsquery(1)HP-UX 11i Version 2: December 2007 Update |
|
NAMEnsquery — query the Name Service Switch backend libraries DESCRIPTIONnsquery is used to find the Name Service that returned the response to a gethostbyname(), gethostbyaddr(), getpwnam(), getpwuid(), getgrnam(), or getgrgid() function call. This application is Name Service Switch aware and follows the lookup policies in /etc/nsswitch.conf. The lookup types supported are:
The lookup query can either be a host name, IP Address, user name, user ID, group name or group ID. The lookup policy must be a valid lookup policy described in nsswitch.conf(4). If the policy is invalid, the system default policy will be used. The default policies are:
nsquery will display the lookup policy being used, the name of the service being queried, and the result of the query. If the result of the query was successful, the appropriate structure will be displayed. EXAMPLESnsquery hosts hondo nsquery hosts 15.204.204.204 "dns files" nsquery passwd dog "nisplus" nsquery passwd 105 nsquery group wayne "nis [NOTFOUND=RETURN] files" nsquery group 22 |
|