Map hostnames to IP addresses

By | June 8, 2020

It is possible to define static hostname-to-address mappings on a Cisco device for the purpose of name resolution. This is usually done in environments without a DNS server.

The mappings can be defined using the global configuration command ip host HOSTNAME IP_ADDRESS:

Floor1(config)#ip host HQ_SERVER

In the output above we’ve defined the IP address of for the hostname HQ_SERVER. To display the hostname-to-address mappings, the show hosts command is used:

Floor1#show hosts
Default Domain is not set
Name/address lookup uses domain service
Name servers are

Codes: UN - unknown, EX - expired, OK - OK, ?? - revalidate
temp - temporary, perm - permanent
NA - Not Applicable None - Not defined

Host Port Flags Age Type Address(es)
HQ_SERVER None (perm, OK) 0 IP

We can ping the server using its hostname to verify that the hostnames are being resolved:

Floor1#ping HQ_SERVER

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to, timeout is 2 seconds:
Success rate is 100 percent (5/5), round-trip min/avg/max = 0/0/1 ms

You can see that HQ_SERVER responded to the ping request, which means that the name resolution was successful.

The drawback of this method of name resolution is that we need to create static hostname-to-address mappings on each device in order to be able to resolve hostnames. If possible, use DNS instead.

Prerequisites for 200-301

200-301 is a single exam, consisting of about 120 questions. It covers a wide range of topics, such as routing and switching, security, wireless networking, and even some programming concepts. As with other Cisco certifications, you can take it at any of the Pearson VUE certification centers.

The recommended training program that can be taken at a Cisco academy is called Implementing and Administering Cisco Solutions (CCNA). The successful completion of a training course will get you a training badge.

Full Version 200-301 Dumps

Try 200-301 Dumps Demo