Unable to ping switches on different subnet/vlan

Answered Question
Feb 1st, 2009

I have two 2960 switches trunked via their respective GE ports and a 2620 router connected to port 1 on switch 1.

Ports 1 thru 12 are in vlan1, while ports 13 thru 24 are in vlan 2.

The router has a sub-interface created and associated to vlan2.

Devices configured as follows:


interface vlan1


interface FastEthernet 0/0

switchport mode trunk

interface FastEthernet 0/0.2

encapsulation dot1Q 2

From the router, I am able to ping the switch connected on port 1 as well as an end device in vlan2 with IP

From the end device, I AM able to ping the gateway - - AND the router but NOT the switch - - that the device is connected to to get to the router.

Any suggestions on what I can do to fix this? Is there anything that I am missing?

I can provide the full running config if required.



I have this problem too.
0 votes
Correct Answer by Leo Laohoo about 7 years 8 months ago

I've just had a look at your config of the 2960 and where's VLAN 2, 3, 4, 10 in the VLAN Database?

vlan 2



vlan 3


  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
darrenoleary Sun, 02/01/2009 - 22:14

Yes, vlan1 interface is open (no shut).

I can ping the vlan1 address from the router OK but no from an end device.

Similarly, I can telnet to the router but not to either of the switches from the end device.

darrenoleary Sun, 02/01/2009 - 22:48

To tell you the truth, I really don't know, but would have to say 'no'.

What should I be looking for in the switch config or what command should I use to configure accordingly?

navinder.singh Mon, 02/02/2009 - 00:21


Try to create the virtual interface for vlan 1 also in router 2620 i.e fa0/0.1

and encapsulation too might be helpful to you

darrenoleary Mon, 02/02/2009 - 01:39

What IP address, if any, should I give it?

Should I keep it as per other sub-interfaces ie 172.16.1.x or doesn't it matter?

darrenoleary Mon, 02/02/2009 - 13:55


Tried this and still no luck unfortunately.

I have attached my configs for the router and the switch for everyones input.


Correct Answer
Leo Laohoo Mon, 02/02/2009 - 17:02

I've just had a look at your config of the 2960 and where's VLAN 2, 3, 4, 10 in the VLAN Database?

vlan 2



vlan 3


darrenoleary Tue, 02/03/2009 - 03:12


Thanks for point that out.

I ended up clearing all config from the router and switch and startign from scratch.

I quickly found that there was other commands that I had either not implemented on either device or had put too much in.

All is working now perfectly. I am able to ping all machines in each subnet as well as each gateway, switch and router from any subnet including 192.168.x.x from any of the 172.16.x.x subnets and vice versa.

thanks again for you help.



darrenoleary Mon, 02/02/2009 - 14:29

Additional to this:

When I connect the end device into any port from 1-12 (vlan1) and attempt to ping any of the 172.16.x.254 addresses, I get no response.

Likewise, when I attempt to ping the same 172.16.x.254 addresses from the switches.


This Discussion