Sorting an array of IP addresses is one of those things that’s not quite as clean and simple as would be nice.
Continue reading ‘Sorting by IP address’ »

I’ve been extended and upgrading my library of network functions for some time now, I thought I’d post the functions that work directly with my original collection.
Continue reading ‘More IPv4 subnet maths with PowerShell’ »

A quick PowerShell 2 function for a Monday evening. A function to return properties from the WinNT provider, most commonly used to enumerate local group membership.
Continue reading ‘Get-LocalGroupMember’ »

I’ve been migrating our Office Communications Server to Lync over the last few days. Last night I started looking at the client policies.

The intention is that we use the in-band-provisioning, which is great, and you’ll find a nice article on Elan Shudnow’s blog.

The client also ships with a group policy template (on retail disk or downloaded from volume licensing) a small number of lines need to be changed as it contains errors.
Continue reading ‘Microsoft Lync: Group Policy Templates’ »

It’s been a while since I’ve posted, and since it’s almost Christmas I thought I’d better get on with it.

Without further ado I want to post NetShell (I’m not very good at coming up with imaginative names). NetShell is a collection of 17 functions and a few supporting functions in a script module.

Download NetShell
Continue reading ‘NetShell’ »

After fixing a couple of authentication bugs with Set-DnsRecord and New-DnsRecord I decided to make an attempt to finish off some of the zone and server CmdLets.

The module now contains these additional CmdLets.

  • Refresh-DnsZone – Implements the ForceRefresh method for Secondary Zones
  • Reload-ADDnsZone – Implements the UpdateFromDS method for AD Integrated Zones
  • Reload-DnsZone
  • Reset-DnsZoneType – Implements the ChangeZoneType method
  • Resume-DnsZone
  • Set-DnsZoneTransfer – Implements the ResetSecondaries method
  • Start-DnsScavenging
  • Start-DnsService
  • Stop-DnsService
  • Suspend-DnsZone – Implements the Pause method
  • Update-DnsZoneFile

As usual, the module can be downloaded from code.msdn.microsoft.com/dnsshell.

A new version of DnsShell has been released, this release improves Get-ADDnsRecord and adds Get-ADDnsPartition and Get-ADDnsZone.

The updated release is available on MSDN as version 0.2.0.

code.msdn.microsoft.com/dnsshell

Basic help is available for each of the new CmdLets.

DnsShell is my PowerShell module intended to help administer MS DNS. This is an alpha relaese, it may contain bugs, it should be tested in a safe environment first.

The module is currently available on MSDN.

The following CmdLets are implemented at this stage:

  • Get-Dns
  • Clear-DnsCache
  • Get-DnsRecord
  • Get-DnsServer
  • Get-DnsZone
  • New-DnsRecord
  • New-DnsZone
  • Remove-DnsObject
  • Set-DnsRecord
  • Get-ADDnsRecord

I am in the process of writing detailed CmdLet help, it will be made available as soon as possible.

A PowerShell script to send a DHCP Discover request and listen for DHCP Offer responses, it can be used for finding DHCP servers (including rogue servers), or for testing DHCP servers and relays. The output from this script is an object containing a decode of the DHCP packet and a number of options.
Continue reading ‘DHCP Discovery’ »

Written to complement the VbScript version of this post. This collection of functions handles subnet maths in PowerShell.
Continue reading ‘IPv4 subnet maths with PowerShell’ »