cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4707
Views
25
Helpful
20
Replies

cant ping to default gateway

daniel4579329
Spotlight
Spotlight

hi 

 

i am learning to ccna and i try to do subinterface between vlans and when i have couple of pc's (with different vlans) i can ping between them, but when i have pc's connect to a switch that connect to a swich and then connect to a router i cant oing to the default gateway

 

thanks for the help (:

20 Replies 20

what i understood from your post is, when you connect user pc with the switch connected to router you are able to communicate between different VLan. once u add another  switch to the above topology and bring all users to the second switch you are not able to ping. can you check the port configuration  between the second and new switch it should be trunk.

And check  port status.



Response Signature


Martin L
VIP
VIP

 

You must have trunks between those switches and switch to Router;

Also, those switches (all switches on the path) should have vlan x,y,z in database that those PCs belong to.  If PC is in access vlan x, but upstream switch does not have vlan x in its database, traffic x is dropped from trunk links.

 

 

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

Richard Burts
Hall of Fame
Hall of Fame

We do not have much detail to work with to understand the issue. I think I understand that some PC is connected to a port in switch 1, switch 1 is connected to a port in switch 2, and switch 2 is connected to a router. Please help us to understand better by answering these questions and providing the requested information:

- is the PC connected to an access port in switch 1? If so the access port is in what vlan? Which port is the PC connected to?

- what is the IP address, mask, and default gateway of the PC?

- are there multiple vlans on switch 1? If so what other vlans exist on switch 1?

- what port on switch 1 connects to what port on switch 2? Is this connection an access port to access port or is the connection configured as a trunk?

- what port on switch 2 connects to the router? Is this connection configured as a trunk?

- please provide the output of these commands on both switches

show interface status

show interface trunk

- please provide the output of these commands on the router

show ip interface brief

show arp

HTH

Rick

Tanks for the reply 

i think this photo will show more information 

 

topology.PNG


if still does not work, attach your PT file here (must be in a zip format)

how do i make it a zip file

about the other questions

 

- the default gateway of each vlan is for example vlan 120 = 192.168.120.0  D.G. -192.168.120.1

 

- output of the left switch (in the photo)

 

Switch#show interfaces status

Port Name Status Vlan Duplex Speed Type

Fa0/1 notconnect 1 auto auto 10/100BaseTX

Fa0/2 connected 120 auto auto 10/100BaseTX

Fa0/3 connected 120 auto auto 10/100BaseTX

Fa0/4 connected 120 auto auto 10/100BaseTX

Fa0/5 connected 120 auto auto 10/100BaseTX

Fa0/6 connected 120 auto auto 10/100BaseTX

Fa0/7 connected 111 auto auto 10/100BaseTX

Fa0/8 notconnect 1 auto auto 10/100BaseTX

Fa0/9 notconnect 1 auto auto 10/100BaseTX

Fa0/10 connected 1 auto auto 10/100BaseTX

Fa0/11 notconnect 1 auto auto 10/100BaseTX

Fa0/12 notconnect 1 auto auto 10/100BaseTX

Fa0/13 notconnect 1 auto auto 10/100BaseTX

Fa0/14 notconnect 1 auto auto 10/100BaseTX

Fa0/15 notconnect 1 auto auto 10/100BaseTX

Fa0/16 notconnect 1 auto auto 10/100BaseTX

Fa0/17 notconnect 1 auto auto 10/100BaseTX

Fa0/18 notconnect 1 auto auto 10/100BaseTX

Fa0/19 notconnect 1 auto auto 10/100BaseTX

Fa0/20 notconnect 1 auto auto 10/100BaseTX

Fa0/21 notconnect 1 auto auto 10/100BaseTX

Fa0/22 notconnect 1 auto auto 10/100BaseTX

Fa0/23 notconnect 1 auto auto 10/100BaseTX

Fa0/24 notconnect 1 auto auto 10/100BaseTX

 

Switch#show interfaces trunk

Port Mode Encapsulation Status Native vlan

Fa0/10 on 802.1q trunking 1

 

Port Vlans allowed on trunk

Fa0/10 1-1005

 

Port Vlans allowed and active in management domain

Fa0/10 1,111,120

 

Port Vlans in spanning tree forwarding state and not pruned

Fa0/10 1,111,120

 

output of the right switch 

 

Switch#show interfaces status

Port Name Status Vlan Duplex Speed Type

Fa0/1 connected 1 auto auto 10/100BaseTX

Fa0/2 connected 80 auto auto 10/100BaseTX

Fa0/3 connected 80 auto auto 10/100BaseTX

Fa0/4 connected 80 auto auto 10/100BaseTX

Fa0/5 connected 111 auto auto 10/100BaseTX

Fa0/6 notconnect 1 auto auto 10/100BaseTX

Fa0/7 notconnect 1 auto auto 10/100BaseTX

Fa0/8 notconnect 1 auto auto 10/100BaseTX

Fa0/9 notconnect 1 auto auto 10/100BaseTX

Fa0/10 connected 1 auto auto 10/100BaseTX

Fa0/11 notconnect 1 auto auto 10/100BaseTX

Fa0/12 notconnect 1 auto auto 10/100BaseTX

Fa0/13 notconnect 1 auto auto 10/100BaseTX

Fa0/14 notconnect 1 auto auto 10/100BaseTX

Fa0/15 notconnect 1 auto auto 10/100BaseTX

Fa0/16 notconnect 1 auto auto 10/100BaseTX

Fa0/17 notconnect 1 auto auto 10/100BaseTX

Fa0/18 notconnect 1 auto auto 10/100BaseTX

Fa0/19 notconnect 1 auto auto 10/100BaseTX

Fa0/20 notconnect 1 auto auto 10/100BaseTX

Fa0/21 notconnect 1 auto auto 10/100BaseTX

Fa0/22 notconnect 1 auto auto 10/100BaseTX

Fa0/23 notconnect 1 auto auto 10/100BaseTX

Fa0/24 notconnect 1 auto auto 10/100BaseTX

 

 

Switch#show interfaces trunk

Port Mode Encapsulation Status Native vlan

Fa0/1 on 802.1q trunking 1

Fa0/4 on 802.1q trunking 1

Fa0/10 on 802.1q trunking 1

 

Port Vlans allowed on trunk

Fa0/1 1-1005

Fa0/4 1-1005

Fa0/10 1-1005

 

Port Vlans allowed and active in management domain

Fa0/1 1,80,111

Fa0/4 1,80,111

Fa0/10 1,80,111

 

Port Vlans in spanning tree forwarding state and not pruned

Fa0/1 1,80,111

Fa0/4 1,80,111

Fa0/10 1,80,111

 

 

output on the router

 

Router#show ip interface brief

Interface IP-Address OK? Method Status Protocol

FastEthernet0/0 unassigned YES manual up up

FastEthernet0/0.80 192.168.80.1 YES manual up up

FastEthernet0/0.90 192.168.90.1 YES manual up up

FastEthernet0/0.100 192.168.100.1 YES manual up up

FastEthernet0/0.110 192.168.110.1 YES manual up up

FastEthernet0/0.111 192.168.111.1 YES manual up up

FastEthernet0/0.120 192.168.120.1 YES manual up up

FastEthernet0/1 unassigned YES unset administratively down down

GigabitEthernet0/2/0 unassigned YES unset administratively down down

Vlan1 unassigned YES unset administratively down down

 

Router#show arp

Protocol Address Age (min) Hardware Addr Type Interface

Internet 192.168.10.1 - 0003.E454.9701 ARPA FastEthernet0/0

 

 

thanks for the help (:

 

 

 

so far I see missing vlan 120 on right switch based on Output of Port Vlans allowed and active in management domain

In Windows, select file, right click, Send To, Compressed Zip file.  Otherwise you can use free 7-zip (choose zip format)

not sure about MACs and Linux but you should have some sort of compressor like WinZip

 

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


please share PT file even if you fix it; looks good!

i added a pc on the right switch with ip and mask and put it on vlan 120, now everything look good but i feel like i didnt understood the problem and how it got fix can you explain to me ?

 

In order for a switch to let pass vlan x traffic thru: 1. switch must have vlan x present in its database (sh vlan). Either Add vlan x to config manually Or switch gets it via VTP.

2.  vlan x must be active (not shut but PT does not have such option, so all are not shut)

and 3. vlan x must be allowed on trunks.

you do not need to have PC in vlan x connecting to that switch that would just pass such vlan traffic.  Note: that command switchport access vlan x  automatically adds vlan x to vlan database.

see show interface trunk and look for vlan x in section Port Vlans allowed and active in management domain (re:1)

Re: 3, look at section Vlan allowed on trunk - it lists vlan that were not manually prohibited (removed) by admin.

 

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

i didnt quite understand " (not shut but PT does not have such option, so all are not shut) " 

 

and i cant make the vlan be in up/up without add a pc on on the switch attached to that vlan 

 

" up/up" is true for interface vlan x which is called SVI.  but SVI is not needed here (switch just passing traffic thru) and does not count for for vlan to be active or inactive (shutdown); 

 

down below you have sw 6, sw 9, sw 5, PC 111.4 and 111.5 are on same network/subnet.  Ping and fix it w/o adding any PCs or SVI on sw9

 


Side Note: PT does not have all options like shutdown vlan. that's why I wrote "active" not shutdown. see attached text file, "before and after" example where I shutdown vlan 50,

and if VTP mode is transparent, show run will show you vlan list:

!
vlan 10,20,30,40
!
vlan 50
shutdown
!

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