Scriptlet: Automated Site Generation

If you find yourself inside a bigger Active Directory Organization, it may be useful to automate the generation of AD sites.

This is what the neat scriptlet will do for you: Generate OU, set Intersite Topology Generation to automatic and protect the freshly generated site from accidential deletion.

It is recommended to use the algorithm of Intersite Topology Generator to define costs and value of connections between sites and not to set it manually. Why? Just a simple reason – over all versions of Windows AD, this algorithm is one of the finest developed ones as this was always a cause for huge replication problems inside a wide-spreaded Active Directory. So let just the built-in robots do the work for you, all manual “finetuning” will only confuse the replication.

This is the scriptlet:

And this is the structure of the textfile you need for it:

And yes, there is no header needed inside this file. Just fill in your seite, start the scriptlet and lean back.

Beside: You can use this scriptlet for preparation of the bigger deal,

Music: Last Train for J.

Last Train for J CoverJust a journey back into time… remember your last journy inside an underground, it seems to be around 3 AM in the morning. This is the last train for today. Immediately, somebody is stepping behind the door in front of you, just looking at you… he seems to be frinedly, a real gentleman. And you and him are starting journey togehter, and the train seems to never stop again.


Script: Add SRV Entries to a Server 2012 environment

With Powershell 3.0, Microsoft introduced a number of new powershell commands for amnaging DNS Server. These commands are tend to replace the well-known dnscmd and are even more powerful and easier to handle. These commands area availbale at least with WIndows Server 2012 and 2012 R2.

At first step, I like to introduce a script helpimg to add numbers of SRV-Entries in a DNS environment. This can be useful when you have to add e.g. numerous SIP-SRV-enbtries or something like this.
Important: The script is asking for a “site” whre the entries should be located, so for larger environments. The sites are usually located like this:
–> _sites
———-> _tcp

The sites are to be defined in the “Sites and Services” at Server Manager of WIndows 2012.

This is the script:

The csv file should be filled in like this:

So, you are able to define those parameters:

  • Sitename
  • FQDN of Server
  • Service like _sip or _sips
  • Used Protocol for this entry, like _tcp or _udp
  • Priority, weight and Port of the entry.

Important: Please use it wiseley and test the script at test environment… I am not repsonible for any errors or misconfigurations done with this script. :-)