Windows Server 8 – Now with PowerShell Cmdlets for DHCPPosted on September 15th, 2011 7 comments
*****Warning. This is from a preview release******
In Windows Server 2008 R2 there were a number of modules included for managing typical server roles such as Active Directory, Failover Clustering etc. However, there were some noteable absentees, such as DHCP server.
You may ask why am I highlighting PowerShell cmdlets for DHCP, well:
- Fellow London VMUG regular Julian Wood commented on my PowerShell v3 First Look Post asking if there were DHCP cmdlets this time.
- Whether there are or not this time would indicate how cmdlet coverage is progressing.
So after firing up Windows Server Developer Preview it was good to see that there are now cmdlets for DHCP Server.
Firstly, add the DHCP Server Role:
…and take a look at the DHCP server module.
Get-Module *DHCP* -ListAvailable
Now, let’s see how many cmdlets we have in that module:
(Get-Command -Module DHCPServer).count
So, let’s have a look at what kind of things we can do.
Get-Command -Module DHCPServer
Let’s try adding a new scope:
Add-DHCPServerv4Scope -Name "Test Scope" -StartRange 192.168.100.50 -EndRange 192.168.100.100 -SubnetMask 255.255.255.0
Now it’s also easy to report on that scope:
Get-DhcpServerv4Scope | Format-List *
The presence of the DHCP Server module is a good indicator that it is now pretty hard to ship a component of Windows Server without adding PowerShell support.
Hopefully 103 DHCP Server cmdlets is enough to make Julian happy
Julian mentions in the comments about DHCP failover and loadbalancing. Haven’t had time to play with the technologies yet, but this might be a good indicator:
Great, this is really enhancing completely integrated management of all MS technologies with PowerShell. Me thinks you will be busy with all the new features!
Now, I hope they actually delivery DHCP Server load balancing and failover.
At last! Can it really be true? Something I’ve been asking for since Windows 2000. Excellent news indeed! Trying to manage any but the smallest installation using the gui is painful, even using crude scripts based upon manipulating NETSH. Looking forward to getting my life back.
That is awesome news indeed, but for those of us unable to roll our production environments over to Windows Server 08, check out the code gallery.
A really awesome addition to DHCP management for us to use right now on production 08 and 03 boxes.
3 Trackbacks / Pingbacks
[...] Windows Server 8 – Now with PowerShell Cmdlets for DHCP [...]
[...] Windows Server 8 – Now with PowerShell Cmdlets for DHCP @ Jonathan Medd’s Blog [...]
Leave a reply