Features on Demand in Server 2012

Windows 8 and Server 2012 introduce a new concept of Features on Demand whereby each installation contains only basic components. Adding new components requires the OS to gather source files from an external location for installation. This is a move away from Server 2008 and Server 2008 R2 where an installation contained everything necessary to service the installation. When adding new features, Windows would simply use its locally cached installation sources.

This was a great concept for home users who no longer needed to worry about having source media, and it resolved a lot of problems for IT administrators having to deal with missing files for patching. The problem was that it drastically increased the size of every installation in the datacenter, chewing up tons of un-needed space. With Server 2012, Microsoft has found a decent balance between the two – provided you configure your environment appropriately.

By default, Server 2012 will go out to Windows Update any time it’s looking for a feature for which it does not have the source files. For example, a common feature that many programs still use for which Windows does not cache installation files locally is the .NET Framework 3.5. Under normal circumstances, you’ll simply use Server Manager to add the new features and never notice the difference. However, if you have a WSUS configured or if the server does not have Internet access, you might see the following error:

Update NetFx3 of Package Microsoft .NET Framework 3.0 failed to be turned on. Status: 0x800f0906.

The error means that Windows was unable to find appropriate source installation files to add the feature. This is because WSUS doesn’t currently support the new Features on Demand functionality in Server 2012. There are a few ways to workaround this issue.

First, you can specify a source from the command line using the Enable-Feature and Source switches for the DISM tool (or -Source parameter from the Install-WindowsFeature powershell command). You can then point to the X:\Sources\Sxs directory to proceed with the installation. The GUI will also allow you to specify this alternate source via the Add Roles and Features Wizard via a yellow warning banner on the confirmation screen.

Second, you can use a GPO or modify the registry to tell Windows to by-pass your WSUS server and go directly to Windows Update when servicing your Server 2012 installation. There are two REG_DWORD values that control this behavior located under [Software\Microsoft\Windows\CurrentVersion\Policies\Servicing]. The first is UseWindowsUpdate – setting this to 2 tells Windows to NEVER go to Windows Update for enabling features. The second is RepairContentServerSource – setting this to 2 tells Windows to go to Windows Update for repair source only (does not affect servicing). Both of these can be controlled via GPO (new Servicing.admx template) under Computer Configuration > Administrative Templates > System > Specify settings for optional component installation and component repair.

Last, you can use a GPO or modify the registry to point Windows to a list of installation source locations – similar to functionality in Server 2003 and XP. These can either be a copy of the X:\Sources\Sxs directory from installation media, or the actual WIM file (either install.wim from installation media or a copy of your company’s customized WIM image). Again, the value is located under [Software\Microsoft\Windows\CurrentVersion\Policies\Servicing]. Setting the REG_EXPAND_SZ value named LocalSourcePath allows you to specify one or more installation source locations (separated by a semicolon). To point to a WIM file, use the following format:

WIM:[path to wim]:[index]

You must specify the index so Windows knows where to find the appropriate installation files for your Server 2012 instance. The nice thing about using a WIM file is that you can perform offline servicing of the image to ensure that it always contains the latest patches and updates.

7 thoughts on “Features on Demand in Server 2012

  1. Pingback: Griffon's IT Library » Win8/Win2012 » Windows 2012 Server-How to install .NET 3.5

  2. Hi Jeff,

    Great information there. I’m currently trying to work out a way to script the installation of .NET Framework 3.5 on the Windows 8 client devices that our customers will no doubt soon be having.
    My problem is that I cannot use the GPO approach as the Servicing.admx file can’t be imported into a 2003 domain and some of our customers are still on 2003. For this reason I want to use the Reg keys that you mention. I’ve added these keys into my test Win 8 VM and tried to do an installation of .NET using DISM with the following command:

    DISM.EXE /online /install-feature /featurename:NetFX3 /All

    However, the command bombs out with an error code 0x800F0907 which, according to http://support.microsoft.com/kb/2734782#appliesto means that the installation has been blocked by Group Policy. Rats!!

    So it’s as if these two Reg keys aren’t working. Is this something you’ve come across yourself?

    • Tim, for .NET 3.5, you need to copy the X:\Sources\Sxs directory and add it to the path. .NET 3.5 isn’t part of the WIM. You can specify multiple source paths using a semicolon between them. We ran into that same issue in our environment with the same error. After copying the SXS directory to a share and updating the regkey, automated installs are now working.

  3. Hi Jeff,

    I’am in the same situation as Tim. I have created a share on one of our Fileservers (I tried with the read permission for the group everyone as well as specific computer accounts). Then I copied the whole content of the \sources\sxs directory to that fileshare.

    After that I created a new group policy (and attatched it to the top of our domain) to publish the path to the share to all servers and clients (I tried with one and multiple, semicolon separated, values).

    Then I did a quick gpupdate /force (I also tried that in combination with a reboot of the machine) and tried to install .net framework 3.5.

    But I still get the error code 0x800F0907.

    (The reguest to add or remove features on the specified server failed. Installation of one or more roles, role services or features failed. Error: 0x800f0907).

    I also use this setting “Never attempt to download payload from Windows Update = enabled”.
    I also tried it in combination with “Contact Windows Update directly to download repair content instead of Windows Server Update Services (WSUS) = enabled” without any success.

    Our clients and server are not allowed to contact windows update servers due to our firewall policy (except the WSUS server).

    Do you have any idea what to do? Cause I have no idea what I have done wrong.

    Best regards,

    • Hi Jeff,
      Hi Tim,

      never mind, I found the solution myself. I didn’t expect that the content in the SXS directory is language specific.

      Regularly all my servers have a german setup. But this one had an english setup.

      So this caused all my troubles. Now I’am going to provide the sxs directory for each language and each server/client version we have in use. That should fix it.

Leave a Reply

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