Adding features (including .NET 3.5) to Windows 10

Windows 10 has created a new way of installing features that aren’t included in the operating system image, kind of like the situation with .NET Framework 3.5 in Windows 8 and Windows 8.1.  Similar, but different.  This enables us to keep the operating system smaller for those that don’t need these features.

To read more about this new “Features on Demand v2”, see the documentation on MSDN (which is where all the ADK documentation can be found now, by the way) at https://msdn.microsoft.com/en-us/library/windows/hardware/mt171094(v=vs.85).aspx.

So if the pieces for these features aren’t included in Windows, where can they be found?  At the moment, in two places:

  • On Windows Update.  As a result, machines connected to the internet can download the pieces that are needed automatically.
  • On MSDN Subscriber Downloads (for those with MSDN subscriptions) and the Volume Licensing Service Center (for those with VL agreements).  There is a “Windows 10 Features on Demand” ISO available for download that can be used for machines that can’t reach the internet.  (There are separate x86 and x64 ISOs.)

(At the moment, these aren’t available in WSUS, but that’s something we’re working on.)  Let’s look at these one at a time.

From the Internet

So how do you add these features?  There are two approaches, manual and automated.  For the manual approach, use the Settings app and navigate to “System –> App & features –> Manage optional features” and click the “+” sign to add a new one.

image

If you noticed that the list took a while to populate, with the spinning progress wheel, that’s because it’s building this list from Windows Update – that can take some time.

For the automated approach, you can use DISM.EXE or PowerShell, take your pick.  To list the available “capabilities” (a rather arbitrary name to separate them from features), just use one of these:

DISM.EXE /Online /Get-Capabilities

Get-WindowsCapability -Online

Both will show the same results, but here’s an example from the PowerShell command (the second one, if you didn’t guess):

image

Notice in that list of couple of items of interest:  NetFx3 (.NET Framework 3.5) and the Insider Hub.

Adding them from the GUI is obvious enough.  From the command line isn’t too bad either:

DISM.EXE /Online /Add-Capability /CapabilityName:NetFx3~~~~

Add-WindowsCapability –Online -Name NetFx3~~~~

Yes, the tilde characters are required, they are part of the name.

From the Media

So back to the other mechanism, the Windows 10 Features on Demand ISO that you can download.  How do you use that?  The basic steps:

  1. Download it.
  2. Extract the contents into a folder, either on the local system or at a network path that the computer can access (open up permissions for domain-joined computers and users).
  3. Tell Windows to use that location.

All you should need to do is tell DISM.EXE or the PowerShell Add-WindowsCapability the path with the Source switch:

DISM.EXE /Online /Add-Capability /CapabilityName:NetFx3~~~~ /Source:C:\Features

Add-WindowsCapability –Online -Name NetFx3~~~~ –Source C:\Features

And as you could do with Windows 8/8.1, you can also specify a “LimitAccess” switch to say “never use anything but the specified source”, if you want to keep it from trying the internet as a fallback.  Unfortunately this isn’t working at the moment, if the machine doesn’t actually have internet access (which kind of defeats the purpose of doing this) – still investigating that.

So that leaves one more question:  What if you wanted to enable the GUI to add these features?  How do you tell it where the extracted features are?  Well, you can’t. The GUI will only talk to the Internet, so you have to use DISM.

From the Media:  A Convenient Workaround

Remember that I said the media isn’t working when you don’t have internet access?  Well, there is a workaround.  The files on the media are CAB files, and those CAB files are actually Windows packages that can be added using:

DISM.EXE /Online /Add-Package /PackagePath:C:\Features\Microsoft-Windows-NetFx3-OnDemand-Package.cab