cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
485
Views
0
Helpful
1
Replies

Change name-server order

jamesl0112
Level 1
Level 1

Hi,

I have some local name-servers configured on a router using the ip name-server command.

The router also knows about some external DNS servers that were supplied via DHCP - the WAN interface uses DHCP to obtain its IP address and gets some DNS servers as well.

However these external servers have never actually been used because the configured local servers were always used first.

Unfortunately the router lost contact with the local servers recently and is now using the external servers first, by default - if a lookup fails it then does not try the others. A lot of local lookups are obviously failing for hostnames that are local, that don't have public DNS entries.

So my question is - is there a way of clearing this name-server priority without shutting the WAN interface or reloading the router? I have tried removing the local DNS servers and re-adding them (no ip name-server xxx.xxx.xxx.xxx, ip name-server xxx.xxx.xxx.xxx), switching off the lookup service (no ip domain-lookup, ip domain-lookup), clearing the hosts table (clear host *) but the router is still stubbornly using the external DNS servers that it failed over to during the internal outage.

Thanks!

1 Reply 1

jamesl0112
Level 1
Level 1

Well - in the end I shut / no shut the outside interface, which forced it to release the DHCP-learned DNS servers:

098312: Jun 5 23:18:34.236 BST: Clearing default gateway and route to x.x.x.x

098313: Jun 5 23:18:34.236 BST: Removing old default route x.x.x.x

098314: Jun 5 23:18:34.240 BST: Clearing route to DHCP server y.y.y.y

098315: Jun 5 23:18:34.240 BST: DHCP: Removing static route to 0.0.0.0 0.0.0.0 via x.x.x.x

098316: Jun 5 23:18:34.240 BST: Clearing DNS address a.a.a.a

098317: Jun 5 23:18:34.240 BST: Clearing DNS address b.b.b.b

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: