background image
384
Chapter 7
Managing a Cisco Internetwork
It doesn't know my name, or what command I am trying to type, so it tries
to resolve this through DNS. This is annoying for two reasons: first, because
it doesn't know my name, and second, because I need to wait for the name
lookup to time out. You can prevent the default DNS lookup by using the no
ip
domain-lookup command on your router from global configuration mode.
If you have a DNS server on your network, you need to add a few com-
mands to make DNS name resolution work:
The first command is ip domain-lookup, which is turned on by
default. It only needs to be entered if you previously turned it off (with
the no ip domain-lookup command).
The second command is ip name-server. This sets the IP address
of the DNS server. You can enter the IP addresses of up to six servers.
The last command is ip domain-name. Although this command is
optional, it should be set. It appends the domain name to the host-
name you type in. Since DNS uses a fully qualified domain name
(FQDN) system, you must have a full DNS name, in the form
domain.com
.
Here is an example of using these three commands:
Todd2509#config t
Enter configuration commands, one per line. End with
CNTL/Z.
Todd2509(config)#ip domain-lookup
Todd2509(config)#ip name-server ?
A.B.C.D Domain server IP address (maximum of 6)
Todd2509(config)#ip name-server 192.168.0.70
Todd2509(config)#ip domain-name lammle.com
Todd2509(config)#^Z
Todd2509#
After the DNS configurations are set, you can test the DNS server by using
a hostname to ping or telnet a device, as shown below.
Todd2509#ping 2501b
Translating "2501b"...domain server (192.168.0.70) [OK]
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.10.2, timeout is
2 seconds:
!!!!!
Copyright ©2002 SYBEX, Inc., Alameda, CA
www.sybex.com