Windows 2012 and .Net 3.5 Feature Install

Windows 2012 Sever RTM was this week, I can think of no better way of honoring it than to write a post on the first thing you will have to work around when installing anything that needs .Net 3.5. While it is well know the .Net is a feature that must be installed separately, what is not obvious is that .Net 3.5 is not actually installed at all on Windows 2012. Which means that if you try the feature install you will have to point it to the source media if you want to use .Net 3.5. No problem just like the old days, just point it to the source directory right? Wrong, sort of.

The nice thing is, when using the GUI it will ask you if you need to supply a source path. 

 

 

The next part is less obvious. On the install media you will find a “\sources\sxs” directory, SxS actually stands for side by side. And if you have ever had to rebuild the SQL Server installer cache you are familiar with it. 

Just for the record, there is an c:\windows\WinSxS directory created when the OS is installed, but, it will not include the .Net 3.5 cache initially. So you must either use the installation media from DVD network or share. Having your windows folks copy just the Sources\Sxs directory to a location you can access is also supported. If your Windows team does not want to give you access to the entire installation media, having just the sxs directory is a good compromise.

Alternatively if you would like to script the install you have two choices.

1. Powershell (As Admin)

Install-WindowsFeature Net-Framework-Core -source \\network\share\sxs

 

2. Old Fashion Command Line (As Admin)

DISM /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:d:\sources\sxs

Using Powershell you can verify the install by running Get-WindowsFeature from within PS, you will notice something similar to this;

 
[X] .NET Framework 3.5 Features NET-Framework-Features Installed
[X] .NET Framework 3.5 (includes .NET 2.0 and 3.0) NET-Framework-Core Installed

Without the LimitAccess option the DISM will try to connect to Windows update whether that is on you network or via internet connection.

All of this magic is outlined in great detail here;

For the windows admin that want to use DISM to patch an offline image, those steps are included as well.
https://msdn.microsoft.com/library/windows/hardware/hh975396