Turning Off DNS lookup on 1841 routers

Durning testing and configuration, even more during the learning process it happens that by mistake we write a command that looks similar to DNS address. During my experiments it happened to me a lot of times, unfortunately the process of DNS lookup can’t be stopped so I was forced to wait it out. Quiet frustrating, even more, when it happens 2-3 times in a row. To avoid that frustrating, but in production so necessary and useful process, its good to turn it off. In the real work environment, I would turn it off also right after first boot, and for the finishing process turn it back on before putting the router to live operation. I can imagine that for some internal networks, which are denied for using the internet and they do not using named internal network devices and DNS servers, the option can stay disabled.

After the router boots up, the first step is to move to EXEC mode ( enable ) than to privileged EXEC mode ( configure terminal ), where we have to issue the next command:

Router (config)# no ip domain lookup

Some of the routers do not have any response message for this command;

We can step back to EXEC mode wit exit or end command;

To make sure that DNS lookup is disabled we can check it in EXEC mode ( Router# ) by show running-config command.

Here we can see that the command succeeded and we do not have wait after mistyped command for the DNS translation.

Be aware that with disabled DNS lookup, the router can only handle IP addresses, and will not translate any kind of website or other domain suspicious name to IP address, so if we want to use a DNS server make sure to allow it again after finished configuration process.

In privileged EXEC mode, we can issue the same command without “no” which allows the DNS translation. (ip domain lookup);

  • And always make sure to save the settings of the router before turning it off by issuing: copy running-config startup-config command;

Comments

Leave a Reply