cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
743
Views
0
Helpful
8
Replies

How to properly distribute IP addresses for VLANs?

andrejdukin51
Level 1
Level 1

There is a range: 192.168.220.128 -192.168.220.255/25

Need to divide into subnets for 4 VLANs of the same maximum possible size within the address
space of this subnet

I get the following:
VLAN 10. 192.168.220.128 - 192.168.220.159/27
VLAN 20. 192.168.220.160 - 192.168.220.191/27
VLAN 30. 192.168.220.192 - 192.168.220.223/27
VLAN 40. 192.168.220.224 - 192.168.220.255/27

Also, on the switch, you need to configure a virtual interface VLAN1 for remote connection and configuration. According to the condition, the IP address of the virtual interface is the last address of the device in this network

What address should I take for VLAN1? 192.168.220.254 from VLAN40? Or do I need to divide the network into 5 VLANs with a mask of 28 and take the address from the range for VLAN1

8 Replies 8

andrejdukin51
Level 1
Level 1

Topology

671d2905c6467477053626.png

@andrejdukin51 

 This is not clear. "in this network".

Which network?  basically you have 4 networks

192.168.220.128/25. It needs to be divided by 4 VLAN

What you can do is, instead 4 network /27, divide in 4 network with /28. This will give you 16 networks with 14 hosts each.

You can use one network, the last one, for Vlan 1. But, the exercise need to be clear on what you need to do.

 

192.168.220.240 192.168.220.241 - 192.168.220.254 192.168.220.255

And if you rename VLAN 40 to VLAN 1. 2 PCs - 192.168.220.225/27 and 192.168.220.226/27. And the vlan1 on the switch is 192.168.220.254/27

Or is this incorrect? Since traffic will be sent to the virtual interface, it may interfere with connecting via ssh or telnet

You can not use the same IP range in two vlans. When you create the interface vlan, this is like two interfaces. The router will complain about IP overlap.

 If you were to use 192.168.220.254/27 for vlan 1, you can not add this same segment in a different vlan.

Why dont you take the whole 192.168.220.0/24 and then split it accordingly? Why are you using 192.168.220.128/25 only.

If this is part of the exercise, again, they need to be clear on it.

I mean it will end up being 4 VLANS:
VLAN 10. 192.168.220.128 - 192.168.220.159/27
VLAN 20. 192.168.220.160 - 192.168.220.191/27
VLAN 30. 192.168.220.192 - 192.168.220.223/27
VLAN 1. 192.168.220.224 - 192.168.220.255/27

I'm using 192.168.220.128/25 because it's part of exercise

Cristian Matei
VIP Alumni
VIP Alumni

Hi,

   Sounds like you actually require 5 subnets, thus you'd need to build /28's and use the last subnet for VLAN1.

Best,

Cristian.