cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3162
Views
0
Helpful
21
Replies

Using ip-helper without using DHCP functionality

jamesedmonds
Level 1
Level 1

Hello,

 

I am fairly new to Cisco, and am after a bit of help.

 

My scenario:

We have a new domain setup on a new VLAN (3), seperate from our current infrastructure VLAN (2).

The new domain controllers provide DHCP for our new servers, and I would also like them to handle DHCP for wireless clients.

We have one DHCP scope 10.0.0.0 255.255.0.0, and I would like to assign all wireless clients an IP in the 10.0.6.0 range.

My thinking on the best way to do this, is with a DHCP policy, that looks at the relay agent information.

I would then set the ip-helper address, on the port the wireless access point is connected to on the Cisco, to point to the DHCP server.

Then for that same port, I would seb a subscriber id in the relay agent information, and use this string to set the IP assigned to that device.

 

Looking into doing this, it seems the Ciscos DHCP functionality has to be turned on in order to use ip-helper.

In my config, I cannot tell if DHCP is enabled or not, I can see neither "service dhcp", nor "no service dhcp" in the config.

 

Assuming I were to turn it on using "service dhcp", can I then leave the actual functionality turned off? i.e. turn on the DHCP service, but not have it assign IP addresses?

Also, does turning it on cause any downtime or disruption?

 

I think I have to run these commands:

conf t

service dhcp

interface GigabitEthernet2/40

Ip helper-address 10.0.0.1

Ip dhcp relay information option-insert

Ip dhcp relay information option subscriber-id “wireless”

 

I know these are probably simple questions, so please forgive my ignorance.

 

James

21 Replies 21

James

 

It is interesting that IOS would accept those commands on interface Gig2/40. But if it is not working right then I wonder if it would help to put those commands under interface vlan 3 also.

 

Can you help us understand better what is not working. You say that the DHCP server is not assigning addresses in the right range. Can you tell us what range you want it to be and what range it is assigning? It might also be helpful to share with us the complete configuration of vlan 3.

 

It might also be helpful to review the scopes configured on the server and to share with us information about what is set up on the server.

 

HTH

 

Rick

HTH

Rick

Ok here goes.

On my domain controller/DHCP server, I have a scope setup of 10.0.0.0 255.255.0.0, and is set with an IP range of 10.0.0.1 - 10.0.6.253

I have various reservations in place, and a working policy to assign thin clients an IP of 10.0.2.X based on their MAC address.

I have then created a second policy, that should be assigning IPs in the 10.0.6.0 range, based on relay agent information, subscriber ID. This is a HEX value, so whatever string I enter on the Cisco, has to be converted to HEX.

This DHCP server is on the same VLAN 3. The VLAN interface on the Cisco has IP of 10.0.0.254 255.255.0.0

The wireless clients are getting IP addresses, but not within the range specified by the policy, so they are getting any address between 10.0.0.1 and 10.0.6.253 that is not already in use.

 

Image 1 shows the vlan interface, where I have set the helper address, relay information option-insert, and subscriber id of "wireless".

Image 2 shows the config on the port that my access point is connected to.

Image 3 shows the value of the policy on the DHCP server, based on subscriber ID

Image 4 shows the string "wireless" converted to HEX

Image 5 shows the IP range that the policy should be using

Image 6 shows "Edss-iPhone" as have an IP not within the correct range

 

Hopefully that helps.

 

James

 

I must admit that I have not read the outputs that you posted - because there is a very significant detail in your recent post: "This DHCP server is on the same VLAN 3". If the DHCP server is in the same VLAN then you do not need any ip helper-address commands because the DHCP server will receive the DHCP request from the client directly and does not need the DHCP relay functions. And I suspect that the IP dhcp relay information commands are not changing anything because  the switch is not relaying any DHCP requests. I wonder if there is a way to achieve the parameters in the DHCP request from the wireless device?

 

HTH

 

Rick

HTH

Rick

Hi James

I have not used the relay information options before so I am unsure why they are not working. It looks setup correctly on the Cisco so I suspect the issue may be with the DHCP server. The one way to prove it would be to setup a packet capture and look at the DHCP messages when a Wireless client tries to obtain an IP address to see if you can see the extra options in there. This would prove if the Cisco is not adding them or if the Server is not processing them properly.

As you already have a large /16 scope for 10.0.*.*, why not use something outside this range such as 10.1.0.0 /24?

255.255.0.0 with a subnet address of 10.0.0.0 only emcompasses 10.0.0.0 to 10.0.255.255.

You could happily setup a new subnet of 10.1.0.0 /24 on the Cisco, even reusing the Vlan3 SVI with an IP address of maybe 10.1.0.1 255.255.255.0 and then setup a scope on the server of 10.1.0.100 - 10.1.0.200. Still use a helper address of 10.0.0.1 on the Vlan3 SVI and it should work fine.

Thanks for all the help everyone!


I decided in the end to create a new VLAN, with a range of 10.100.0.0. 255.255.0.0 (a lot of 10.X between 0 and 100 are in use, so making it this high ensures I am not overlapping).

I then set the IP helper address for this VLAN interface, and put the wireless on there.

I then just created a second scope on the DHCP server and all is working well!

 

Thanks again for helping out a newbie.

James

Hi James

Glad its working :)

One thing I would point out for the future is that using a /16 subnet mask (255.255.0.0) is not really best practice. You should look to use something like a /24 or /24 as it conserves addresses.

Thanks

James

 

Glad that you got it working. Creating a new VLAN and using the helper-address and relay options is a reasonable solution. Thanks for posting back to let us know that you got it working.

 

Good luck as you continue to learn about networking. Continue to be active in the forum.

 

HTH

 

Rick

HTH

Rick