Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

Single VLAN can support multiple subnets

Hi all,

I was reading cisco book where it says Sinle vlan can support multiple subnets.Because switch ports are configured for vlan  number only and not a network address any station connected to a poprt can present  ant subnet address range.

if someone can please explain me this with example.

thanks

mahesh

2 ACCEPTED SOLUTIONS

Accepted Solutions

Re: Single VLAN can support multiple subnets

As stated above, there are some circumstances where you can have multiple IP subnets in the same VLAN.

I think however, that we come to the same conclusion where you should have a 1-to-1 relation between VLAN and IP subnets as a recommended design.

If you find yourself in a situation where you must aggregate different subnets on the same VLAN, my opinion is to consider a redesign.

VLANs are L2 and are just a concept that switches know about and IP subnets are L3.

So, as I said, technically you can have multiple IP subnets on the same VLAN but again, not recommended solution.

Federico.

VIP Super Bronze

Re: Single VLAN can support multiple subnets

Hi Mahesh,

Take a look at the config example I have below:

interface Vlan10
ip address 20.20.20.1 255.255.255.0 secondary
ip address 30.30.30.1 255.255.255.0 secondary
ip address 10.10.10.1 255.255.255.0
end

Again, not recommended but this is just for your info:

HTH

Reza

9 REPLIES
VIP Super Bronze

Re: Single VLAN can support multiple subnets

Hi Mahesh,

Yes, it is possible to have multiple subnets in the same vlan. You would just assign multiple subnets under the same vlan interface but it is not a common practice at all.  The cleanest way is to have one subnet per vlan to keep you broadcast domains separate.

HTH

Reza

Re: Single VLAN can support multiple subnets

As Reza said, the recommendation is to have:

1 VLAN = 1 IP subnet = 1 Broadcast Domain

VLAN is a L2 concept, therefore technically is possible to have multiple IP subnets (L3) on the same VLAN.

However this practice is not recommended at all.

Federico.

Community Member

Re: Single VLAN can support multiple subnets

There some legimate reasons to have multiple IP subnets on the same vlan.  For example, you might need to increase the size of a subnet due to address exhaustion.  If an adjacent subnet isn't available to supernet with, one possible solution is to add another subnet as a secondary IP interface.  A large drawback to this solution is that hosts in the same vlan, but in different subnets, would require a router to communicate.

While this might serve well as a migration tool, it isn't the cleanest way to configure a network.  It is still better to have a 1:1 relationship between vlans and ip subnets.

Later,

Dave

Community Member

Re: Single VLAN can support multiple subnets

Hi,

thanks for replying.

if you can explain me with example how can we do this?

thanks

mahesh

Re: Single VLAN can support multiple subnets

As stated above, there are some circumstances where you can have multiple IP subnets in the same VLAN.

I think however, that we come to the same conclusion where you should have a 1-to-1 relation between VLAN and IP subnets as a recommended design.

If you find yourself in a situation where you must aggregate different subnets on the same VLAN, my opinion is to consider a redesign.

VLANs are L2 and are just a concept that switches know about and IP subnets are L3.

So, as I said, technically you can have multiple IP subnets on the same VLAN but again, not recommended solution.

Federico.

Community Member

Re: Single VLAN can support multiple subnets

Hi thanks for great reply

i mean to know command  syntax for multiple subnets on single vlan

this i need to know only?

thanks

mahesh

Re: Single VLAN can support multiple subnets

Depends on your setup.

For example, if you have a L2 switch.... computers can connect to ports on the same VLAN, and the computers belonging to different subnets.

No extra configuration needed.

Federico.

VIP Super Bronze

Re: Single VLAN can support multiple subnets

Hi Mahesh,

Take a look at the config example I have below:

interface Vlan10
ip address 20.20.20.1 255.255.255.0 secondary
ip address 30.30.30.1 255.255.255.0 secondary
ip address 10.10.10.1 255.255.255.0
end

Again, not recommended but this is just for your info:

HTH

Reza

Community Member

Re: Single VLAN can support multiple subnets

Hi all,

Many thanks for all for answering the question

thanks

mahesh

45215
Views
10
Helpful
9
Replies
CreatePlease to create content