cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
8929
Views
35
Helpful
18
Replies

I can not ping from one PC2 (vlan 10) to PC1 (vlan 20) with trunking (ROAS)

Leerical
Level 1
Level 1

Good morning all,

I've been following a video series that teaches VLANs, trunking, and subinterfaces. However, no matter how much I try to follow along I am not able to replicate the results of the video series. I've tried at least 5 times. My problem starts when I try to configure the router with subnets (encapsulation dot1q, etc). I then create a trunking connection to the switch from the router. Yet, no success in being able to communicate between PC2 (VLAN 10) to PC1 (VLAN 20). Any suggestions?pinging from PC2 to PC1pinging from PC2 to PC1RouterRouterSwitch 1Switch 1Switch 2Switch 2

1 Accepted Solution

Accepted Solutions

Leerical,

Make sure a couple of things:-
1) Check the IP address on the PCs. For example, if you configure on PC2: IP address:192.168.1.6, Subnet Mask: 255.255.255.128 and Gateway: 192.168.1.1; and on PC1: IP address 192.168.1.150, Subnet Mask: 255.255.255.128 and Gateway: 192.168.1.129, then you will need to correct the configuration on the Router as follows:

interface GigabitEthernet0/0.10
encapsulation dot1Q 10
ip address 192.168.1.1 255.255.255.128
!

interface GigabitEthernet0/0.20
encapsulation dot1Q 20
ip address 192.168.1.129 255.255.255.128
!

2) To be sure, configure fa0/20 on Switch1 as follows:
int fa0/20
switchport access vlan 10
switchport mode access
!

P.S.:- By the way, thank you for the rating. However, You do not need to rate for all replies.

HTH,
Meheretab
HTH,
Meheretab

View solution in original post

18 Replies 18

PaulSmith
Level 1
Level 1

Check if int gig 0/1 is administratively down. It has to be up for int gig 0/0.10 to be up.

Hey Paul!

Thanks for the reply. Yes, it is up. 

Router ip int brief (pane)Router ip int brief (pane)

Hi

 

Does each PC ping the IP adress of the router on their vlan ?

If not :

1) verify the netmask of the interface of each PC. You are sharing the same Class C subnet into two /25 subnets. It is a common issue to keep 255.255.255.0 (/24) as netmask...

2) please verify that vlans 10 and 20 are correctly set up :

- sh vlan brie : to verify that both vlans 10 and 20 are present on each switch

- sh run int <name_if> : to verify the config of port switch of each PC and in front of the router

 

In front of the router, the swith port should look like :

int <name_if>

switchport mode trunk

no shut

! add this if you want to limit vlans

!  switchport trunk allowed vlan 10,20

Regards

 

Jérôme

Neither PC's will ping the Router.

 

2.) Switch 1 does not have vlan 20 on it because the switch port connecting to the next switch is trunked. Cisco Packet Tracer - C__Users_Robert Lexie_Desktop_Network Academy 1.1.pkt 8_7_2018 10_53_29 AM.png

I can't quite make out your diagrams, but have you added both vlans to all the switches in the path?

Trunk ports can only carry the VLANs that are actually on the switches. Even if you have set them up correctly on the router, you must then add them to all the switches with the following command example:

 

conf t

vlan 10

exit

 

This will create the vlan on the switches, ready to be passed along trunk ports. If you have missed a switch and haven't added either of the VLANs, it's not going to work.

 

Hope that helps. Apologies if I have misunderstood.

 

M.S Rees1, you're good. I think I may have thought from earlier post that if the VLAN is connected to a port it won't work. However, I checked, and both VLAN's are on both switches. It's just that on one switch the VLAN isn't assigned to a port. 

See any issues with this?

 

SwInt.PNG

Hi Leerical,

 

Let's backup a little bit and start from the basics:

VLANs -- are used to create different LANs. Devices on different VLANs are not able to communicate to each other unless you have a layer 3 device. One way of routing traffic between different VLANs is using ROAS as you configured here --> using subinterfaces. If there are switches, as in your case, you will need to have trunk ports to carry multiple VLANs (if you have more than one VLAN). Trunk ports are used to pass traffics from multiple VLANs as far as the VLANs are configured on the switches.

 

In your case, if you can not ping from PC2 on VLAN 10 to PC1 on VLAN 20, please follow the steps below:

1) Check whether vlan 20 is configured on Switch 2

2) check whether vlan 10 and vlan 20 is configured on Switch 1

3) check if the port between switch 1 and switch 2 is configured as trunk ports

4) check if the port between switch 1 and Router 2 is configured as trunk port on switch 1 side

 

If you have configured everything and it still not working, please share your configuration for switch 1, switch 2 and router 2.

 

 

P.S.:- Please do not forget to rate correct answers and resolve once you find the correct solution.

 

HTH,

Meheretab

HTH,
Meheretab

See any issues with this?

SwInt.PNG

 

I do not see any issue with the configuration of trunk ports. Could you share what is configured on the port connected to PC2? Also, please share similar configurations on SW1 as well?

HTH,
Meheretab
HTH,
Meheretab

sw1sw1sw2sw2

 

PC2 is connected to an access port on f0/1

Please share the output of "sh run" on both switches and the router so that we could look your configuration and guide you in the right direction.
HTH,
Meheretab

Switch#show run (Switch 1)

Switch#show running-config

Building configuration...

 

Current configuration : 1210 bytes

!

version 12.2

no service timestamps log datetime msec

no service timestamps debug datetime msec

no service password-encryption

!

hostname Switch

!

!

!

!

!

spanning-tree mode pvst

spanning-tree extend system-id

!

interface FastEthernet0/1

switchport access vlan 10

switchport mode access

!

interface FastEthernet0/2

switchport trunk allowed vlan 10,20

switchport mode trunk

!

interface FastEthernet0/3

!

interface FastEthernet0/4

!

interface FastEthernet0/5

!

interface FastEthernet0/6

!

interface FastEthernet0/7

!

interface FastEthernet0/8

!

interface FastEthernet0/9

!

interface FastEthernet0/10

!

interface FastEthernet0/11

!

interface FastEthernet0/12

!

interface FastEthernet0/13

!

interface FastEthernet0/14

!

interface FastEthernet0/15

!

interface FastEthernet0/16

!

interface FastEthernet0/17

!

interface FastEthernet0/18

!

interface FastEthernet0/19

!

interface FastEthernet0/20

!

interface FastEthernet0/21

!

interface FastEthernet0/22

!

interface FastEthernet0/23

!

interface FastEthernet0/24

!

interface GigabitEthernet0/1

switchport mode trunk

!

interface GigabitEthernet0/2

!

interface Vlan1

no ip address

shutdown

______________________________________________________________________________

 

hostname Switch2

!

!

!

!

!

spanning-tree mode pvst

spanning-tree extend system-id

!

interface FastEthernet0/1

switchport mode trunk

!

interface FastEthernet0/2

!

interface FastEthernet0/3

switchport access vlan 10

switchport mode access

!

interface FastEthernet0/4

!

interface FastEthernet0/5

!

interface FastEthernet0/6

!

interface FastEthernet0/7

!

interface FastEthernet0/8

!

interface FastEthernet0/9

!

interface FastEthernet0/10

!

interface FastEthernet0/11

!

interface FastEthernet0/12

!

interface FastEthernet0/13

!

interface FastEthernet0/14

!

interface FastEthernet0/15

!

interface FastEthernet0/16

!

interface FastEthernet0/17

!

interface FastEthernet0/18

!

interface FastEthernet0/19

!

interface FastEthernet0/20

switchport access vlan 20

!

interface FastEthernet0/21

!

interface FastEthernet0/22

!

interface FastEthernet0/23

!

interface FastEthernet0/24

!

interface GigabitEthernet0/1

!

interface GigabitEthernet0/2

!

interface Vlan1

no ip address

shutdown

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:

Review Cisco Networking products for a $25 gift card