NETWORK ADMINISTRATIONSWindows serverwindows server dhcp

Create DHCP scopes using PowerShell on windows server 2008 R2! Easier way!

This videos shows the alternative solution to create dhcp scope using powershell even though your DHCP server is hosted in 2008 R2

Here’s the command to install DHCP module in powershell:

Add-WindowsFeature -Name DHCP -IncludeManagementTools

Two commands to create DHCP scopes with complete options:

(Here Computername means DHCP server name)

Add-DhcpServerv4Scope -ComputerName “192.168.0.20” -Name “My Second DHCP Scope” -Description “My Rirst DHCP scope” -StartRange “192.168.0.50” -EndRange “192.168.0.60” -SubnetMask 255.255.255.0 -LeaseDuration 3.00:00:00 -State Active

Set-DhcpServerv4OptionValue -ComputerName “192.168.0.20” -Router “192.168.0.1” -DnsServer “192.168.0.10” -DnsDomain “dran.com” -ScopeId 192.168.0.0

source by Dran TechSolutions

windows server dhcp

Leave a Reply

Your email address will not be published. Required fields are marked *