Skip to main content

vserver services name-service getxxbyyy getaddrinfo

Contributors
Suggest changes

Gets the IP address information by using the host name.

Availability: This command is available to cluster administrators at the advanced privilege level.

Description

The ` vserver services name-service getxxbyyy getaddrinfo ` gets the IP address information by using the host name for a given Vserver. The underlying service for doing the lookup is selected based on the configured name service switch order.

Parameters

-node {<nodename>|local} - Node Name (privilege: advanced)

Use this parameter to specify the node where the lookup will be performed

-vserver <vserver name> - Vserver Name (privilege: advanced)

Use this parameter to specify the Vserver where the lookup will be performed

-hostname <text> - Host Name (privilege: advanced)

Use this parameter to specify the Host Name for which the IP address information is needed

[-address-family {ipv4|ipv6|all}] - Return Addresses for Family (privilege: advanced)

Use this parameter to specify the Address Family for which the IP address information is needed

[-show-source {true|false}] - Show Source used for Lookup (privilege: advanced)

Use this parameter to specify if source used for lookup needs to be displayed

[-use-cache <true>] - Enable/Disable cache (privilege: advanced)

If set to true , locally-cached values will be used. The default value is false .

Examples

The following example requests address information for localhost:

cluster1::*> vserver services name-service getxxbyyy getaddrinfo -node cluster1-01 -vserver vs1 -hostname localhost -address-family all -show-source true -use-cache false
   Source used for Lookup: Files
   Host name: localhost
   Canonical name: localhost
   IPv4 : 127.0.0.1
   IPv6 : ::1