Displays information from the hosts database. If the BIND resolver is enabled, information from the BIND database is also displayed. Related commands: SET HOST Format SHOW HOST [ host ] [ /ADDRESS=IP_address ] [ /DOMAIN=domain ] [ /LOCAL ] [ /OUTPUT=file ] [ /SERVER=server ]
1 – Restrictions
Requires read access to the hosts database.
2 – Parameters
host Optional. Default: All hosts. All alias names for the specified host are displayed. o If a host has more than one IP address and you specify the name, all its addresses and aliases are displayed. o If a host has multiple IP addresses and you specify an alias that is defined on multiple IP addresses, only the first IP address and aliases are displayed. o If you do not specifiy the host parameter or if you use a wildcard, all hosts from the local and BIND databases are displayed. o If you use a wildcard to complete a host name, no BIND information is displayed. o If you specify a host, entries are displayed first from the local hosts database, if they exist; otherwise, entries from the BIND database are displayed, if they exist.
3 – Qualifiers
3.1 /ADDRESS
/ADDRESS=IP_address Optional. Default: None. Allows you to select a host by IP address. o If a host has more than one IP address and you specify the name, all IP addresses and aliases for the host are displayed. o If a host has multiple IP addresses and you specify an alias that is defined on multiple IP addresses, only the first IP address and aliases are displayed. o Recommended: Use the host parameter instead of this qualifier.
3.2 /DOMAIN
/DOMAIN=domain Optional. Default: Name service domain. Domain to be used by the local host. However, the definition of the domain name is valid only during the execution of the current SHOW HOST command. The BIND request is sent to the specified domain.
3.3 /LOCAL
Optional. Limits name-to-address lookups to the local hosts database.
3.4 /OUTPUT
/OUTPUT=file Optional. Default: Screen display. Specifies a file for the output of the SHOW HOST command.
3.5 /SERVER
/SERVER=server Optional. Default: Name server list. BIND servers to be used. The definition of the server name list is valid only during the execution of the current SHOW HOST command. The request is sent to the specified server. The list is ordered by request preference. For example, the initial request is sent to the first host in the list. If that host is unavailable, the request is sent to the second host in the list, and so on. You can specify a maximum of three servers.
4 – Examples
1.TCPIP> SHOW HOST /LOCAL The /LOCAL qualifier displays only the hosts in the local database. 2.TCPIP> SHOW HOST ABCXYZ Displays information about a host found in the BIND database. Note that the display includes the name and address of the BIND server that supplied the information. 3.TCPIP> SHOW HOST * Displays the entire hosts database and BIND database (if the resolver is enabled). In the following examples, host heron has the following IP addresses and aliases: IP AddressHost Aliases 100.1 heron HOST_1A HOST_1B HOST_ALIAS 100.2 heron HOST_2A HOST_2B HOST_ALIAS 4.TCPIP> SHOW HOST HERON Shows all the IP addresses and aliases for the host HERON. 5.TCPIP> SHOW HOST HOST_1A Shows IP address 100.1 and the aliases HOST_1A, HOST_1B, and HOST_ALIAS. 6.TCPIP> SHOW HOST HOST_ALIAS Shows the host and all aliases for addresses 100.1 and 100.2. Shows all the IP addresses and aliases for host heron.