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

Quick VLAN Question.

nelson.garcia
Level 1
Level 1

I've noticed in my L2 2960 Cisco switch that you can configure a VLAN by typingg in (from global config mode):

vlan #

or

int vlan #

My question is, why is there these two options?

I can assign a name to my VLAN when i type in

vlan 20

name (name)

but not when I go

interface vlan 20

name (name)

unrecognized command.

So my question is, what's the difference between the two?

Thanks a lot =)

1 Accepted Solution

Accepted Solutions

Nelson

Apologies, should have been more specific :-).

Where i said

"The 2960 is a L2 switch only so you can only create 1 L3 vlan interface and this interface is used so you can remotely connect to the switch."

i should have said that you can create more than 1 L3 vlan interface but only one can be active ie up/up at one time.

Jon

View solution in original post

4 Replies 4

Jon Marshall
Hall of Fame
Hall of Fame

Nelson

They are not the same thing.

1) vlan in global config mode creates the vlan at layer 2. You can create multiple vlans at layer 2 on the 2960 switch and you can then allocate ports into these vlans.

2) int vlan 20

this does not create a L2 vlan. It creates a L3 vlan interface or SVI (Switched Virtual Interface). To route between vlans you need L3 vlan interfaces. The 2960 is a L2 switch only so you can only create 1 L3 vlan interface and this interface is used so you can remotely connect to the switch.

A L3 switch such as the 3560/3750/4500/6500 can have multiple L3 vlan interfaces.

So L2 switch can have multiple L2 vlans + 1 L3 vlan interface.

L3 switch can have multiple L2 vlans + multiple L3 vlan interfaces.

Jon

Thank you for the informative and quick reply Jon.

Nelson

Just a quick followup Jon. While I don't deny that your answer was correct. I tested out what you said about L2 switches only allowing 1 L3 VLAN interface.

I went into global config mode and created

int vlan 20

ip address # subnet #

and

int vlan 30

ip address # subnet #

I then (from privileged exec mode) typed

sh ip int bri

and both interface vlan 20 and interface vlan 30 showed up on the list, albeit down.

Is this supposed to happen?

Nelson

Apologies, should have been more specific :-).

Where i said

"The 2960 is a L2 switch only so you can only create 1 L3 vlan interface and this interface is used so you can remotely connect to the switch."

i should have said that you can create more than 1 L3 vlan interface but only one can be active ie up/up at one time.

Jon

Review Cisco Networking for a $25 gift card