cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3303
Views
5
Helpful
8
Replies

Loopback Address Help

So I'm attempting to configure a loopback address on my Cisco cat-3850 Switch to be pingable on a host PC. 

The devices are already connected via an Ethernet cord and despite the fact that, if the Switch goes through to the Router, it can reach the internet, the host PC is not able to ping the loopback address at all.

 

Currently, the ports in use are all Switchports, and I'm not sure if I'm meant to make any of them Layer 3 ports to make the loopback visible. 

 

What am I missing?

1 Accepted Solution

Accepted Solutions

The original post talks about a connected host PC, a switch with a loopback interface, and a router. I am not clear what interface is the PC and what interface connects to the router. And I am not clear what role the router has if the question here is about the ability of the host PC to ping the loopback interface. 

 

It is good that the configuration is posted. It wold be even better if you would indicate which switch port connects to the host PC. It would also be helpful if you would post the output of ipconfig from the PC.

 

The one thing that I will note from looking at the switch config is that you have configured ip default-gateway and have not configured a static default route. ip default-gateway works when a switch is operating as a layer 2 switch to define a default gateway. But when you configure ip routing on the switch it becomes a layer 3 switch and the default-gateway command is ignored. So you probably need to configure a static default route for the switch.

HTH

Rick

View solution in original post

8 Replies 8

Reza Sharifi
Hall of Fame
Hall of Fame

What is the loopback address for?

Is the 3850 working as layer-2 switch? If yes, you don't need a loopback address. All you need is a vlan with an SVI for management use. If the switch is layer-3, than you need to enable ip routing on the switch to be able to route between 2 different interfaces (Ethernet and loopback).

HTH 

I am going to be using it as a Layer 3 switch, and I've enabled IP Routing. Is there anything I'm supposed to do after that?

When you logon to the switch, can you ping the loopback as well as the switch management IP?

Can you post "sh run" from the switch?

HTH

Sorry, I was away for a bit, and this is going to be rather long:

 

ip routing
!
!
!
!
!
!
!
!
!
cpp system-default
!
!
!
!
!
diagnostic bootup level minimal
spanning-tree mode rapid-pvst
spanning-tree extend system-id
!
!
redundancy
 mode sso
!
!
!
class-map match-any system-cpp-police-topology-control
  description Topology control
class-map match-any system-cpp-police-sw-forward
  description Sw forwarding, L2 LVX data, LOGGING
class-map match-any system-cpp-default
  description DHCP Snooping, EWLC control, EWCL data
class-map match-any system-cpp-police-sys-data
  description Learning cache ovfl, Crypto Control, Exception, EGR Exception, NFL SAMPLED DATA, Gold Pkt, RPF Failed
class-map match-any system-cpp-police-punt-webauth
  description Punt Webauth
class-map match-any system-cpp-police-l2lvx-control
  description L2 LVX control packets
class-map match-any system-cpp-police-forus
  description Forus Address resolution and Forus traffic
class-map match-any system-cpp-police-multicast-end-station
  description MCAST END STATION
class-map match-any system-cpp-police-multicast
  description Transit Traffic and MCAST Data
class-map match-any system-cpp-police-l2-control
  description L2 control
class-map match-any system-cpp-police-dot1x-auth
  description DOT1X Auth
class-map match-any system-cpp-police-data
  description ICMP redirect, ICMP_GEN and BROADCAST
class-map match-any system-cpp-police-stackwise-virt-control
  description Stackwise Virtual
class-map match-any system-cpp-police-control-low-priority
  description General punt
class-map match-any non-client-nrt-class
class-map match-any system-cpp-police-routing-control
  description Routing control
class-map match-any system-cpp-police-protocol-snooping
  description Protocol snooping
!
policy-map system-cpp-policy
 class system-cpp-police-data
  police rate 600 pps
 class system-cpp-police-sys-data
  police rate 100 pps
 class system-cpp-police-sw-forward
  police rate 1000 pps
 class system-cpp-police-multicast
  police rate 500 pps
 class system-cpp-police-multicast-end-station
  police rate 2000 pps
 class system-cpp-police-punt-webauth
  police rate 1000 pps
 class system-cpp-police-l2-control
  police rate 2000 pps
 class system-cpp-police-stackwise-virt-control
  police rate 8000 pps
 class system-cpp-police-routing-control
  police rate 5400 pps
 class system-cpp-police-control-low-priority
  police rate 200 pps
 class system-cpp-police-l2lvx-control
  police rate 1000 pps
 class system-cpp-police-topology-control
  police rate 13000 pps
 class system-cpp-police-dot1x-auth
  police rate 1000 pps
 class system-cpp-police-protocol-snooping
  police rate 2000 pps
 class system-cpp-police-forus
  police rate 1000 pps
 class system-cpp-default
  police rate 1000 pps
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface Loopback1
 ip address 192.168.4.120 255.255.255.0
!
interface GigabitEthernet0/0
 vrf forwarding Mgmt-vrf
 no ip address
 shutdown
 speed 1000
 negotiation auto
!
interface GigabitEthernet1/0/1
!
interface GigabitEthernet1/0/2
!
interface GigabitEthernet1/0/3
!
interface GigabitEthernet1/0/4
!
interface GigabitEthernet1/0/5
!
interface GigabitEthernet1/0/6
!
interface GigabitEthernet1/0/7
!
interface GigabitEthernet1/0/8
!
interface GigabitEthernet1/0/9
!
interface GigabitEthernet1/0/10
!
interface GigabitEthernet1/0/11
!
interface GigabitEthernet1/0/12
 no switchport
 ip address 192.168.1.234 255.255.255.0
!
interface GigabitEthernet1/0/13
 shutdown
!
interface GigabitEthernet1/0/14
 shutdown
!
interface GigabitEthernet1/0/15
 shutdown
!
interface GigabitEthernet1/0/16
 shutdown
!
interface GigabitEthernet1/0/17
 shutdown
!
interface GigabitEthernet1/0/18
 shutdown
!
interface GigabitEthernet1/0/19
 shutdown
!
interface GigabitEthernet1/0/20
 shutdown
!
interface GigabitEthernet1/0/21
 shutdown
!
interface GigabitEthernet1/0/22
 shutdown
!
interface GigabitEthernet1/0/23
 shutdown
!
interface GigabitEthernet1/0/24
 shutdown
!
interface GigabitEthernet1/0/25
 shutdown
!
interface GigabitEthernet1/0/26
 shutdown
!
interface GigabitEthernet1/0/27
 shutdown
!
interface GigabitEthernet1/0/28
 shutdown
!
interface GigabitEthernet1/0/29
 shutdown
!
interface GigabitEthernet1/0/30
 shutdown
!
interface GigabitEthernet1/0/31
 shutdown
!
interface GigabitEthernet1/0/32
 shutdown
!
interface GigabitEthernet1/0/33
 shutdown
!
interface GigabitEthernet1/0/34
 shutdown
!
interface GigabitEthernet1/0/35
 shutdown
!
interface GigabitEthernet1/0/36
 shutdown
!
interface GigabitEthernet1/0/37
 shutdown
!
interface GigabitEthernet1/0/38
 shutdown
!
interface GigabitEthernet1/0/39
 shutdown
!
interface GigabitEthernet1/0/40
 shutdown
!
interface GigabitEthernet1/0/41
 shutdown
!
interface GigabitEthernet1/0/42
 shutdown
!
interface GigabitEthernet1/0/43
 shutdown
!
interface GigabitEthernet1/0/44
 shutdown
!
interface GigabitEthernet1/0/45
 shutdown
!
interface GigabitEthernet1/0/46
 shutdown
!
interface GigabitEthernet1/0/47
 shutdown
!
interface GigabitEthernet1/0/48
 shutdown
!
interface GigabitEthernet1/1/1
 shutdown
!
interface GigabitEthernet1/1/2
 shutdown
!
interface GigabitEthernet1/1/3
 shutdown
!
interface GigabitEthernet1/1/4
 shutdown
!
interface TenGigabitEthernet1/1/1
 shutdown
!
interface TenGigabitEthernet1/1/2
 shutdown
!
interface TenGigabitEthernet1/1/3
 shutdown
!
interface TenGigabitEthernet1/1/4
 shutdown
!
interface Vlan1
 no ip address
 shutdown
!
ip default-gateway 192.168.1.1
ip forward-protocol nd
ip http server
ip http authentication local
ip http secure-server
!
!
!
!
!
control-plane
 service-policy input system-cpp-policy
!
!
line con 0
 exec-timeout 20 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
 exec-timeout 20 0
 password 7 151019190C
 logging synchronous
 login
line vty 5 15
 login
!
!
wsma agent exec
!
wsma agent config
!
wsma agent filesys
!
wsma agent notify
!
!
end

The original post talks about a connected host PC, a switch with a loopback interface, and a router. I am not clear what interface is the PC and what interface connects to the router. And I am not clear what role the router has if the question here is about the ability of the host PC to ping the loopback interface. 

 

It is good that the configuration is posted. It wold be even better if you would indicate which switch port connects to the host PC. It would also be helpful if you would post the output of ipconfig from the PC.

 

The one thing that I will note from looking at the switch config is that you have configured ip default-gateway and have not configured a static default route. ip default-gateway works when a switch is operating as a layer 2 switch to define a default gateway. But when you configure ip routing on the switch it becomes a layer 3 switch and the default-gateway command is ignored. So you probably need to configure a static default route for the switch.

HTH

Rick

In addition to Rick's questions, I don't see an SVI for the vlan the PC is in. Is the PC supposed to be in vlan1 or in another vlan?

If you are planning to use the switch as layer-3, than you need an SVI with an IP on the same subnet as the PC.

Example:

PC IP 192.168.10.2/24

SVI on the switch

interface vlan1

description data vlan or user vlan

ip address 192.168.10.1 255.255.255.0

no sh

 

HTH

 

I am glad that my comments pointed you in the right direction. ip default-gateway is sometimes a bit confusing and I am glad that you now have a better understanding of it. Thank you for marking this question as solved. This will help other participants in the community to identify discussions which have helpful information. This community is an excellent place to ask questions and to learn about networking. I hope to see you continue to be active in the community.

HTH

Rick

Martin L
VIP
VIP


those 3850 are tricky but L3 switches can communicate via SVI. you can add SVI so that you can route with router (SVI and routed port or sub-interface port on same subnet).  then, check ip routing table on sw to see if both SVI and loopback subnets are there.   you can enable routing protocol on switch and advertise your loopback but static route on a router should be enough (static route for loopback network pointing to SVI IP on sw as next hop)

what is your routing table of sw now?

 

Regards, ML
**Please Rate All Helpful Responses **