cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2465
Views
0
Helpful
4
Replies

different vlans but same subnet

arakesh12345
Level 1
Level 1

iam created the different switches having the same subnet  

SW1(vlan 10)=====SW2-- (vlan 20)pc2( vlan 20) sw mo access

 |

   |

   PC1(vlan 10) sw mode access

they are pinging 

but how they are pinging with different vlans   

please explain anyone they are different access ports

4 Replies 4

Julio E. Moisa
VIP Alumni
VIP Alumni

Hi 

Yes if you are connecting 2 switches with ports over different vlan you will be able to ping each other it is because the frame are sent an untagged. But this scheme is not scalable. The vlan id is local for each switch unless you are doing propagation as VTP does. You could have some CDP problems but it will work fine.

:-)




>> Marcar como útil o contestado, si la respuesta resolvió la duda, esto ayuda a futuras consultas de otros miembros de la comunidad. <<

here different vlans means different networks,if different networks communicate only by routing or intervlan routing 

 how pc1 communicate with pc2

with different vlans

Hi

If they are same subnets but in different vlans it could work:

SW1

interface vlan 10
ip add 192.168.1.1 255.255.255.0

interface fa0/1
P2P-to-SW2
switchport access vlan 10

SW2

interface vlan 20
ip add 192.168.1.2 255.255.255.0

interface fa0/1
description P2P-to-SW1
switchport access vlan 20

but as you mentioned they are different subnets, it could work if you are using secondary networks or if the switch is a layer 3 device with ip routing command line enabled. 

Example:

SW2

interface vlan 20
ip add 192.168.1.2 255.255.255.0
ip add 2.2.2.2 255.255.255.255 secondary

interface fa0/1
description P2P-to-SW1
switchport access vlan 20

Could you please share the model of switch and the configuration?




>> Marcar como útil o contestado, si la respuesta resolvió la duda, esto ayuda a futuras consultas de otros miembros de la comunidad. <<

Diana Karolina Rojas
Cisco Employee
Cisco Employee

Hello!

When a frame do not cross a trunk port it is not encapsulated with the vlan tag, so If you has configured that ports they can have conecction.

------PD: Do not forget to rate useful post-----

Regards,