Changes

Jump to: navigation, search
Configuring Scopes at the Command Prompt
Command completed successfully.
</pre>
 
== Activating and Deactivating DHCP Scopes using Netsh ==
 
DHCP scopes must be activated before they can be used and may also be deactivated at any time. Both of these tasks may be performed at the command prompt using the '''netsh'' tool. For example, to activate a scope the following command line syntax is used:
 
'''netsh dhcp server''' ''serverID'' '''scope''' ''subnetID'' '''state''' ''status''
 
where ''serverID'' is the name or IP address of the computer running the DHCP server, ''subnetID'' is the network ID of the subnet on which the scope is to be configured, and ''status'' is either 1 or 0 depending on whether the scope is to activated (1) or deactivated (0). On a switched network with multiple virtual networks are hosts on a single network use 2 and 3 respectively to deactivate and activate the scope.
 
== Terminating a DHCP Lease using Netsh ==
 
The lease associated with an IP address may be terminated at the command prompt using the following command syntax:
 
'''netsh dhcp server''' ''serverID'' '''scope''' ''subnetID'' '''delete lease''' ''IPaddress''
 
where ''serverID'' is the name or IP address of the computer running the DHCP server, ''subnetID'' is the network ID of the subnet on which the IP address resides, and ''IPaddress'' is the IP address on which the lease is to be terminated. For example,
 
<pre>
netsh dhcp server \\winserver-1 scope 192.168.2.0 delete lease 192.168.2.101
</pre>

Navigation menu