Windows Server 2016 – Changing the desktop background using Group Policy

So, who’s idea was that?

How many of you are running Sever 2016? have you noticed the default background for the desktop experience is the same as Windows 10.  That’s great for marketing but a pain in the posterior when you are flicking between servers and workstations that have the exact same desktop.  It maybe my age but I wanted an automatic way of changing the background on the 2016 servers so I had a fighting chance of identifying which machine I was using.

Preparing the background image

First off you are going to need a background image, this is going to be 3840×2160 in size so it’ll scale to most RDP screen sizes.  In my case I simply grabbed the default wallpaper from the server (they can be found in C:\Windows\Web\4K\Wallpaper\Windows).  Or if you’re feeling lazy you can download my edited version here.

Next we need to put the image somewhere that it will always be available.  Again here I dropped the image into the NETLOGON share on the domain within a sub-folder.  That way it’ll get replicated around the domain as well.

Windows Server 2016 - Changing the background with GPO

Group Policy Configuration

Right, lets fire up Group Policy Management.

To start with we’ll create a new Group Policy Object, I’ll call it “Windows Server 2016 – Desktop Background”

Windows Server 2016 - Changing the background with GPO

The policy setting that we want to edit is under “User Configuration” -> “Policies” -> “Administrative Templates” -> “Desktop” -> “Desktop” -> “Desktop Wallpaper”

Windows Server 2016 - Changing the background with GPO

Double click the “Desktop Wallpaper” setting

Windows Server 2016 - Changing the background with GPO

  • Click “Enable”
  • Set the wallpaper name to the UNC of the location of your desktop image file i.e. \\domain.com\NETLOGON\Backgrounds\WindowsServer2016Background.jpg
  • Set the “Wallpaper style” to “Fill”
  • Click “OK”

Within the same GPO navigate to “Computer Configuration” -> “Policies” -> “Administrative Templates” -> “System” -> “Group Policy” and locate the GP setting called “Configure user Group Policy loopback processing mode”

Windows Server 2016 - Changing the background with GPO

Enable this setting and change the “Mode” to “Replace”

The reason for this setting is to ensure that the “User Configuration” settings are applied to the server when the user logs in.  If this setting isn’t configured the policy won’t get applied to the server because the GPO is only associated to a OU with server (computer) objects.  Once done we can close this window and return to the Group Policy Management screen.

Ok, as mentioned above this GPO is going to be applied to the server OUs however I suspect that your server OUs also contain Windows 2008/2012/2012R2 servers and you don’t want a Server 2016 desktop applied to these servers.  To stop this from happening we can create a WMI filter that’ll single out Server 2016 servers.

So…from Group Policy Management find “WMI Filters”, right click it and select “New”

Windows Server 2016 - Changing the background with GPO

Give it a name and description i.e. “Windows Server 2016”

In the queries window click “Add” and add the following query

select * from Win32_OperatingSystem where Version like “10.%”

Windows Server 2016 - Changing the background with GPO

This query will ensure that the OS version is 10  (i.e. Server 2016) and won’t apply to any OS versions below this.  Click “OK” and click “Save” to exit the WMI filter window.

Applying the GPO

Ok, so we have our nice new GPO created, the background image on the server and finally a WMI filter created to ensure that only 2016 Servers get the new background.

We just need to apply this GPO to the OU container that houses the servers, in my example I am targeting the DCs.  Then we need to set the WMI filter on the GPO to be the one we just created above.

Windows Server 2016 - Changing the background with GPO

All needs to be done now is to run GPUPDATE on the servers.  Log off and log back in and see that nice new background!

5 thoughts on “Windows Server 2016 – Changing the desktop background using Group Policy

  1. Gerwim

    Thanks!

    I actually used the following WMI query to target actually ONLY servers and not clients (not depending on OU):

    select * from Win32_OperatingSystem where Version like “10.%” and (ProductType=”3″ or ProductType=”2″)

    ProductType 3 are “regular” servers while ProductType 2 are domain controllers.

    Reply
  2. Gary Walrath

    I really like the idea of a server only background. In the process to implement this, I keep getting an error window stating
    ” Group Policy Management
    A Syntax error occurred trying to evaluate a query string”

    Got any advice on this?

    Reply
    1. Rob Post author

      Hi Gary

      If you’ve cut n paste the string from the site is possible the characters aren’t formatted correctly, particularly the quotes. Try copying the string into NotePad and replace the quotes then copy the string into WMI filter.

      Rob

      Reply
  3. Michael Miller

    Just thought I’d comment here cause this was a useful jumpstart read for me. I was trying to get separate wallpaper GPOs accomplished on Windows Server 2019 boxes… and Server 2019 is classified as version 10.0 just like Server 2016. Thanks Microsoft (*internal screaming*)

    So, after a visit to Reddit, this is what we came up with:
    Select * from Win32_OperatingSystem WHERE BuildNumber = 17763 and (ProductType=”3″ or ProductType=”2″)

    I got the build numbers from Microsoft here: https://support.microsoft.com/en-us/help/3119213/wmi-group-policy-filters-that-compare-win32-operatingsystem-buildnumbe — Take note: 17763 is Windows 10 1809 AND Server 2019, which is why the specifier for ProductTypes is necessary. Product Type 1 is regular PC’s, so you could easily change this to only select Windows 10 1809 boxes if you wanted.

    Hope this helps future Googler!

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *