Search This Blog

Monday, June 09, 2014

Prevent RAS leasing IPs from DHCP server

We had a Windows 2008 R2 server that was setup as a network policy server, which I believe installed the RAS service. Now the server has been around for a while so I must add that I am not sure if RRAS had been installed in the past and used, and then uninstalled, but RRAS was not installed at this time.

We were having an issue that this RAS server was grabbing blocks of 10 IP addresses from our DHCP server. After looking into this in became apparent that it was probably RRAS that was responsible, however as I say it was not installed. I did not fancy installing the RRAS role (in case it screwed up the current setup).

So…. I went looking for a Registry setting to turn off DHCP leasing for RAS or reduce the number of IPs that it gobbled up. Eventually I cam across this setting, which by default (or absence) is 10. This setting tells RAS how many IP addresses to grab.

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\RemoteAccess\Parameters\IP
Value Name: InitialAddressPoolSize
Data Type: REG_DWORD

Now this looked promising so I opened this key in the registry, and then stumbled across this beauty. This seemed to be more to my liking… actually turning DHCP leasing off… Surprised smile

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\RemoteAccess\Parameters\IP
Value Name: InitialAddressPoolSize
Data Type: REG_DWORD
Value: 1

It was set to one, and a quick lookup found something for windows CE, that stated 1=on and 0=off.

  1. So I changed to 0.
  2. deleted the DHCP leases and restarted the RAS service.

Hoorah no more DHCP leases from the RAS server.

I am hoping this is correct, if you want to try it, its at your own risk. But for now it seems to have worked.

References

http://community.spiceworks.com/topic/97183-prevent-ras-entries-in-dhcp


Share/Bookmark