Tuesday, July 16, 2013

SCCM 2012: Maintenance Windows and Business Hours

We all know by now that System Center 2012 Configuration Manager is a client-centric product.  Meaning that, while it gives us admins some power over the system to perform certain tasks, the user is ultimately in control of their device.  One way this is acheived is by the inclusion of "Business Hours" on the client.

I'm not going to go into too much detail on how Business Hours works along with Maintenance Windows, instead please see this wonderful blog post from the MS Server and Cloud Platform Team:


Basically, regardless of the Maintenance Window the power is truely in the hands of the end-user for mandatory deployments.  Lets say, for example, that you have an OOB patch that must be pushed out immediately ... soo immediate that you bypass your maintenance windows in order to do it.  If the time is within the Business Hours of the machine (by default its 5AM - 10PM) then the user gets to decide if the installation happens immediately, or if it posponed.

Depending on your patch deployment framework, this can have some serious rammifications if your maintanence windows don't jive properly with Business Hours.  Whats worse is that since Business Hours is a client-side ONLY setting, you can't set this via the ConfigMgr console.

- BUT -

You CAN set this via VBScript or via PowerShell.  Rather than rinse/repeat, here are links to two blogs that outline how to do this:

VBScript (Piped through Google Translate)


Given the nature of this I would suggest applying this script at logon to ensure that all systems get updated with an appropriate time.  It should also be added to your Task Sequence so that reimaged systems start with the adjusted Business Hours.

Have Fun!

Friday, July 12, 2013

How to Configure TimeZones dynamically during Imaging (Take Two!)

A few years ago I had posted what I "THOUGHT" was a method to resolve the TimeZone issue that many of us struggle with but it turned out that not only was I completly wrong, but I was actually barking up the wrong tree!

TimeZone configuration can be a major headache when your enterprise spans multiple timezones, or multiple countries, if you are trying to keep your imaging strategy basic and easy to maintain.  I'm not a huge fan of splitting imaging into numerous collections with each collection given their own Task Sequence Variable to identify TimeZone since that just takes too much work, and I'm lazy!  Up until now I have been just dealing with imaging in one TimeZone then manually adjusting based on the region, totally not efficient!

I came across this excellent blog post which explains it quite well:


Basically, rather than rely on a TS Variable, instead use a VB Script at the end of your Task Sequence that will automatically adjust the timezone based on the DHCP server it is connecting too.  As the blog states, the account used to run this script needs to have read rights to the registry on the DHCP server, but it works qutie beautifully.

Check it out!