the opposite, in some ways, of hostname_to_ip, ip_to_hostname consumes a vector of IP addresses and provides a list of the hostnames that those IPs resolve to. Compatible with both IPv4 and IPv6 addresses.

ip_to_hostname(ip_addresses)

Arguments

ip_addresses
a vector of IP addresses.

Value

a list, each entry containing a vector of hostnames for the equivalent input IP address (mostly, this will only be one hostname but not always). If the IP cannot be resolved, the list element will be the string "Invalid IP address".

See also

hostname_to_ip, for the reverse operation.

Examples

## Not run: ------------------------------------ # ip_to_hostname("162.243.111.4") # [[1]] # [1] "dds.ec" ## ---------------------------------------------