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

VLAN - DHCP

silverfoxx
Level 1
Level 1

we have seven floor building and planning to introduce VLANs in our FLAT network structure, question is that wether it is possible that I can create VLAN floors based and at the same time would want that every floor only recevie the IP from DHCP according to there floor number

e.g. 2nd floor machines will get machine 1 = 172.16.2.2

machine 2 = 172.16.2.3 and so on for each floor

The DHCP server is on the 5th floor and every floor has 2 2950 switches while 5th floor has 6500 switch as core. is it possible or not and how any helpful tip. thanks is advance

1 Accepted Solution

Accepted Solutions

Roberto Salazar
Level 8
Level 8

previous post is correct. Just to give you a better picture, take the following topology as example,:

DHCP Server--subnetA---e0 router e1---subnetB---PC1

e2

|

|

subnetC

|

|

PC2

The drawing above might not come out as intended, so I'll describe here. DHCP is connected to router via ethernet0, PC1 in subnetB is connected to e1 of the same router and PC2 in subnetC is connected to e2 of the same router.

The router will have the following configuration:

e0

ip address a.a.a.1/24

e1

ip address b.b.b.1/24

ip helper-address a.a.a.x >> address of the DHCP server

e2

ip address c.c.c.1/24

ip helper-address a.a.a.x >> address of the DHCP server

Of course the DHCP will need to have it's scope properly configured for each subnet. How will DHCP know which subnet requested an IP address? It will know since the router translate broadcast request from the PCs to unicast bootp to the DHCP server and act as relay agent. This action for simplicity sake is how the DHCP know which subnet the requester is on and assign ip address according to it's scope.

View solution in original post

2 Replies 2

pkhatri
Level 11
Level 11

Hi,

That is certainly possible. DHCP servers will, by default, assign IP addresses out of the same range as the address on the first router interface that the DHCP DISCOVER message was received on.

Therefore, in your case, if you have a single DHCP server with scopes set up for your 7 networks (corresponding to your 7 floors), your hosts will receive the correct addresses.

You will need to setup inter-vlan routing to communicate between your VLANs. Then, you will need to configure IP helper-addresses on your vlan interfaces (if you are using one of your switches to do inter-vlan routing). When the DHCP messages are relayed, they will carry information on which router interface address it was received. Therefore, if a request comes in from the vlan1 interface, which has an IP of 172.16.1.1, the DHCP server will assign addresses out of the 172.16.1.x range....

Hope that helps - pls rate the post if it does.

Paresh

Roberto Salazar
Level 8
Level 8

previous post is correct. Just to give you a better picture, take the following topology as example,:

DHCP Server--subnetA---e0 router e1---subnetB---PC1

e2

|

|

subnetC

|

|

PC2

The drawing above might not come out as intended, so I'll describe here. DHCP is connected to router via ethernet0, PC1 in subnetB is connected to e1 of the same router and PC2 in subnetC is connected to e2 of the same router.

The router will have the following configuration:

e0

ip address a.a.a.1/24

e1

ip address b.b.b.1/24

ip helper-address a.a.a.x >> address of the DHCP server

e2

ip address c.c.c.1/24

ip helper-address a.a.a.x >> address of the DHCP server

Of course the DHCP will need to have it's scope properly configured for each subnet. How will DHCP know which subnet requested an IP address? It will know since the router translate broadcast request from the PCs to unicast bootp to the DHCP server and act as relay agent. This action for simplicity sake is how the DHCP know which subnet the requester is on and assign ip address according to it's scope.