Installing .Net 3.5 on Server 2012/ Windows 8 and above

Hi all, just a quick post to serve as both a reminder to me and hopefully something helpful for you. For some reason Microsoft has decided to make installing .Net 3.5 on anything after Windows Server 2012 (or Windows 8 on the client side) harder than it has to be. While it is included in the regular Windows Features GUI it is not included in the on-disk sources for features to be installed automatically. In a perfect world you just choose to source from Windows Update and go about your day, but in my experience this is a hit or miss solution as many times for whatever reason it errors out when attempting to access. The fix is to install via the Deployment Image Servicing and Management tool better known as DISM and provide a local source for the file. .Net 3.5 is included in every modern Windows CD/ISO under the sources\sxs directory. When I do this installation I typically use the following command set from an elevated privilege command line or PowerShell window:

When done the window should look like the window to the left. Pretty simple, right? While this is all you really need to know to get it installed let’s go over what all these parameters are that you just fed into your computer. /online – This refers to the idea that you are changing the installed OS as opposed to an image /enable-feature – the is the CLI equivalent of choosing Add Roles and Features from …

Updating the Photo Attributes in Active Directory with Powershell

Today I got to have the joys of needed to once again get caught up on importing employee photos into the Active Directory photo attributes, thumbnailPhoto and jpegPhoto. While this isn’t exactly the most necessary thing on Earth it does make working in a Windows environment “pretty” as these images are used by things such as Outlook, Lync and Cisco Jabber among other. In the past the only way I’ve only ever known how to do this is by using the AD Photo Edit Free utility, which while nice tends to be a bit buggy and it requires lots of repetitive action as you manually update each user for each attribute. This year I’ve given myself the goal of 1) finally learning Powershell/PowerCLI to at least the level of mild proficiency and 2) automating as many tasks like this as possible. While I’ve been dutifully working my way through a playlist of great PluralSight courses on the subject, I’ve had to live dangerously a few times to accomplish tasks like this along the way. So long story short with some help along the way from Googling things I’ve managed to put together a script to do the following. Look in a directory passed to the script via the jpgdir parameter for any images with the file name format <username>.jpg Do an Active Directory search in an OU specified in the ou parameter for the username included in the image name. This parameter needs to be the full DN path (ex. LDAP://ou=staff,dc=foo,dc=com) …

Quick How To: A restart from a previous installation or update is pending.

Just a quickie from an issue I ran into today trying to upgrade vCenter 5.5 to Update 3, or at least the SSO component of it. Immediately after running the installer I was presented with an MSI error “A restart from a previous installation or update is pending. Please restart your system before you run vCenter Single Sign-On installer.” Trying to be a good little SysAdmin I dutifully rebooted, repeatedly, each having no effect on the issue. I’ve seen different versions of this error in the past so I had an idea of where to go but it seems to require googling each time. This is caused by there being data present in the “PendingFileRenameOperations” value of the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager key. Simply checking this key and clearing out any data within will remove the flag and allow the installation to proceed. In this case I had an HP print driver doing what they do best and gumming up the works. I’d love to say this is the first time I’ve been done in by a print driver but you all would know I’m lying. 🙂