cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4529
Views
1
Helpful
25
Replies

Issues with DNS resolutions

BrunoVic
Level 1
Level 1

I am having issues with DNS resolutions from a switch connected to a gateway router. What's interesting is that I can ping from the switch just fine which shows me that there is connectivity to the internet however DNS resolutions don't work. I thought maybe something is blocking DNS at the ISP however the router can resolve DNS just fine. So why does the router resolve fine but the switch doesn't IF both the switch and the router have internet connectivity?

25 Replies 25

balaji.bandi
Hall of Fame
Hall of Fame

before start config other command :

 

From switch are you able to ping .8.8.8.8 ? Then configure as below to resolve the Domain name

 

config)# ip name-server 8.8.8.8

(config)# ip domain lookup

 

 

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Yes so I did exactly that already. I am able to ping 8.8.8.8 from the switch and I did configure the namer-server to 8.8.8.8 as well as made sure ip domain lookup is enabled and it still does not resolve. If you want I can give you the debug as well.

 

v/r

BVIC

=~=~=~=~=~=~=~=~=~=~=~= PuTTY log 2021.10.08 11:54:54 =~=~=~=~=~=~=~=~=~=~=~=
ping google.com

*Oct 8 15:58:30.069: Reserved port 5762 in Transport Port Agent for UDP IP type 1
*Oct 8 15:58:30.069: UDP: sent src=192.168.42.2(5762), dst=8.8.8.8(53), length=47
*Oct 8 16:00:30.069: Released port 5762 in Transport Port Agent for IP type 1
*Oct 8 16:00:30.069: Released port 5762 in Transport Port Agent for IP type 1

% Unrecognized host or address, or protocol not running.

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

what is this device model, and what IOS code running

 

here is common document we use :

 

https://www.cisco.com/c/en/us/support/docs/ip/domain-name-system-dns/24182-reversedns.html

 

show version  and show run  should help to give more help.

 

Also on router it working what DNS Server it using ?

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Switch#show ver
Cisco IOS XE Software, Version 17.03.01
Cisco IOS Software [Amsterdam], Catalyst L3 Switch Software (CAT9K_IOSXE), Version 17.3.1, RELEASE SOFTWARE (fc5)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2020 by Cisco Systems, Inc.
Compiled Fri 07-Aug-20 21:32 by mcpre


Cisco IOS-XE software, Copyright (c) 2005-2020 by cisco Systems, Inc.
All rights reserved. Certain components of Cisco IOS-XE software are
licensed under the GNU General Public License ("GPL") Version 2.0. The
software code licensed under GPL Version 2.0 is free software that comes
with ABSOLUTELY NO WARRANTY. You can redistribute and/or modify such
GPL code under the terms of GPL Version 2.0. For more details, see the
documentation or "License Notice" file accompanying the IOS-XE software,
or the applicable URL provided on the flyer accompanying the IOS-XE
software.


ROM: IOS-XE ROMMON
BOOTLDR: System Bootstrap, Version 17.3.1r[FC2], RELEASE SOFTWARE (P)

Switch uptime is 2 weeks, 1 day, 26 minutes
Uptime for this control processor is 2 weeks, 1 day, 28 minutes
System returned to ROM by PowerOn
System image file is "flash:packages.conf"
Last reload reason: PowerOn

Oh and on the router yes it is working and I am using the same exact DNS setup as the switch.

 

BTW that document is the one I used awhile back. I've already seen that document.

I have same Cat 9300 working as expected ((CAT9K_IOSXE), Version 17.3.3,)

 

ip name-server 8.8.8.8
ip domain lookup source-interface Gix/x ( worth try out going interface  - towards Router)

 

#ping google.com
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 142.250.200.46, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 8/8/9 ms

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

I am still having the same problem:

 

Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#ip domain look
Switch(config)#ip domain lookup sour
Switch(config)#ip domain lookup source-interface vlan 20
Switch(config)#do ping google.com
% Unrecognized host or address, or protocol not running.

Switch(config)#

My bad I changed the source interface to the physicals interface connected to the router. I still get the same results too.

 

v/r

BVIC

Can you ping as below :

 

#ping 8.8.8.8 source vlan 20

 

below below config :

 

show run

show run interface vlan 20

show  interface vlan 20

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Ok I've tried this before and it didn't work but it seems to work now.

 

Switch#ping 8.8.8.8 source vlan 20
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 8.8.8.8, timeout is 2 seconds:
Packet sent with a source address of 192.168.42.2
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 16/16/16 ms
Switch#

This intresting.

 

Router IP address Lan side 192.168.42.1 ?

 

Try change 8.8.8.8 with 192.168.42.1

 

still issue  - post below output from switch

 

show ip interface brief

show ip route

 

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Hello,

 

on the router, debug:

 

debug ip udp

 

Then send a ping to www.google.com and post the output...

I already posted the debug output above

 

Re: Issues with DNS resolutions - Cisco Community

Review Cisco Networking for a $25 gift card