Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements
Webcast-Catalyst9k
New Member

layer 2 vs layer 3

guys i have a v simple question suppose we have a router and switch (layer three swicth) now if we give 192.168.1.1/24 ip at router ethernet and then make a swicth port as routed and give ip address of 192.168.1.2/24 it will work and ping will be fine now the scenario is same but the only difference is we make swicth port to access port and make a vlan 10 and assign ip 192.168.1.2/24.....now it will work as well all i am trying to ask is what is the main difference btw these two scenarios.......expect that we can add other pc with same range and they can use the vlan

1 REPLY

Re: layer 2 vs layer 3

The main thing is in the switch - if you configure the switch port as a layer 3 interface with an IP address and the routers - effectivly you have created a pt-pt link on the IP subnet.

No other switch port can take part in the broadcast domain.

If you create an SVI in a vlan and give the SVI an IP address, then any port configured in the switch and anyother switch connected via a trunk port will be able to participate in the broadcast domain.

HTH>

118
Views
0
Helpful
1
Replies
CreatePlease to create content