Hello everyone. If you haven’t heard, the Windows Server 8 Beta dropped today and boy, am I excited! It’s like a kid in a candy store. I’ll be doing a few blog posts on some of the changes as well as their impact on SQL Server. The first one I’m going to look at is .NET Framework which we all know is required for SQL Server deployments.

.NET Versions

.NET 3.51

.NET 3.51 is still required by SQL Server 2012 – even under Windows Server 8.

.NET 4.0

.NET 4.0 is a new requirement for SQL Server 2012.While .NET 4.0 is out of band with Windows Server 2008 and Windows Server 2008 R2 (meaning it shipped after the release of those OSes, so you need to install them separately), it is in band for Windows Server 8 since it ships with an early version of .NET 4.5. This means that you do not need to install .NET 4.0 separately and is already installed by default (see Figure 1 below). This will cut down the installation time for SQL Server 2012.

Installing and Troubleshooting .NET 3.51 Installations for SQL Server 2012 on Windows Server 8

If .NET 3.51 is not installed, SQL Server will detect this during Setup as shown in Figure 1. As you can see, SQL Server knows it needs to be enabled (“Windows feature(s) to be turned on:”), and will attempt to do so during the installation process.

.NET 3.51 Required

Figure 1. Setup showing .NET 3.51 needs to be installed, .NET 4.0 is already installed by default in Windows Server 8

Once you get through the configuration screens, Setup will start installing SQL Server. The status shown in Figure 2 is where .NET is attempted.

Setup installing .NET 3.51

Figure 2. Setup attempting to install .NET 3.51

So far, so good – right? Wrong! I ran into this:

Enabling .NET 3.51 failing

Figure 3. Houston – we have a problem.

Needless to say, this was not something I wanted to see. Delving into the verbose SQL Server Setup log file (detail.txt), I saw this:

[cc]

(01) 2012-03-01 01:19:48 Slp: Running Action: Install_DotNet35_Cpu64_Action
(01) 2012-03-01 01:19:48 Slp: Sco: File ‘D:x64setupx64dotNetFx35setup.exe’ does not exist
(01) 2012-03-01 01:19:48 Slp: Checkpoint: PREINSTALL_DOTNET35_CPU64_ACTION
(01) 2012-03-01 01:19:48 Slp: Enabling OS feature :NetFx3,  Dism Command: Dism /Online /Enable-Feature /FeatureName:NetFx3  /NoRestart  /Quiet  /All /LogPath:”C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037NetFx3.log”
(01) 2012-03-01 01:19:48 Slp: Running: Dism /Online /Enable-Feature /FeatureName:NetFx3  /NoRestart  /Quiet  /All /LogPath:”C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037NetFx3.log”
(19) 2012-03-01 01:24:42 Slp:
(19) 2012-03-01 01:24:42 Slp: Error: 0x800f0906
(19) 2012-03-01 01:24:42 Slp:
(19) 2012-03-01 01:24:42 Slp: The source files could not be downloaded.
(19) 2012-03-01 01:24:42 Slp: Use the /source option to specify the location of the files that are required to restore the feature. The file location should be either the root directory of a mounted image or a component store that has the Windows Side-by-Side directory as an immediate subfolder.
(01) 2012-03-01 01:24:42 Slp: Process returned -2146498298
(01) 2012-03-01 01:24:42 Slp: Failed to enable OS feature :NetFx3, result: -2146498298
(01) 2012-03-01 01:24:42 Slp: Watson Bucket 1
Original Parameter Values

(01) 2012-03-01 01:24:42 Slp: Parameter 0 : SQL Server 2012 RC0@RC@

(01) 2012-03-01 01:24:42 Slp: Parameter 3 : Microsoft.SqlServer.Configuration.SetupExtension.OSFeatureEnableFailureException@1428@1

(01) 2012-03-01 01:24:42 Slp: Parameter 4 : Microsoft.SqlServer.Configuration.SetupExtension.OSFeatureEnableFailureException@1428@1

(01) 2012-03-01 01:24:42 Slp: Parameter 5 : Install_DotNet35

(01) 2012-03-01 01:24:42 Slp: Parameter 7 : Microsoft.SqlServer.Configuration.SetupExtension.OSFeatureEnableFailureException@1@-2146498298

(01) 2012-03-01 01:24:42 Slp: Parameter 8 : Microsoft.SqlServer.Configuration.SetupExtension.OSFeatureEnableFailureException@1@-2146498298

(01) 2012-03-01 01:24:42 Slp:
Final Parameter Values

(01) 2012-03-01 01:24:42 Slp: Parameter 0 : SQL Server 2012 RC0@RC@

(01) 2012-03-01 01:24:42 Slp: Parameter 3 : 0x681D636F@1428@1

(01) 2012-03-01 01:24:42 Slp: Parameter 4 : 0x681D636F@1428@1

(01) 2012-03-01 01:24:42 Slp: Parameter 5 : Install_DotNet35

(01) 2012-03-01 01:24:42 Slp: Parameter 7 : 0x2F26F1A4

(01) 2012-03-01 01:24:42 Slp: Parameter 8 : 0x2F26F1A4

(01) 2012-03-01 01:24:44 Slp: Sco: Attempting to write hklm registry key Microsoft SQL Server to file C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037Registry_SOFTWARE_Microsoft_Microsoft SQL Server.reg_
(01) 2012-03-01 01:24:44 Slp: Sco: Attempting to write hklm registry key Uninstall to file C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037Registry_SOFTWARE_Microsoft_Windows_CurrentVersion_Uninstall.reg_
(01) 2012-03-01 01:24:44 Slp: Sco: Unable to open hklm registry key SOFTWAREMicrosoftMSSQLServer, error The system cannot find the file specified.
(01) 2012-03-01 01:24:44 Slp: Sco: Attempting to write hklm registry key Microsoft SQL Server to file C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037Registry_SOFTWARE_Wow6432Node_Microsoft_Microsoft SQL Server.reg_
(01) 2012-03-01 01:24:44 Slp: Sco: Attempting to write hklm registry key Uninstall to file C:Program FilesMicrosoft SQL Server110Setup BootstrapLog20120301_011037Registry_SOFTWARE_Wow6432Node_Microsoft_Windows_CurrentVersion_Uninstall.reg_
(01) 2012-03-01 01:24:44 Slp: Sco: Unable to open hklm registry key SOFTWAREWow6432NodeMicrosoftMSSQLServer, error The system cannot find the file specified.
(01) 2012-03-01 01:24:47 Slp: Error while enabling Windows feature : NetFx3, Error Code : -2146498298 , Please try enabling Windows feature : NetFx3 from Windows management tools and then run setup again. For more information on how to enable Windows features , see http://go.microsoft.com/fwlink/?linkid=227143
(01) 2012-03-01 01:24:47 Slp: Watson bucket for exception based failure has been created
[/cc]

In other words, it failed because it couldn’t find the right “thing” to install .NET 3.51 from.

So how did I troubleshoot? It’s simple. There are a few ways to configure features in Windows. One of the easiest is to use the command line tool dism.

I first checked what was enabled (or not), and saw this:

Seeing feature statusFigure 4. There’s definitely a problem!

Note the state of NetFx3 (the feature you want to install) – “Disabled with Payload Removed”. Don’t panic – the fix is pretty simple. dism allows you to specify where to find that file if for some reason it isn’t in the OS. Assuming you have access to the installation media,use the /source option of dism to specify where to find the file. In this case, I was given a clue in detail.txt in this part “a component store that has the Windows Side-by-Side directory as an immediate subfolder”. In looking at the Windows Server 8 installation media, there was a sourcessxs folder. I plugged that in and viola! Success!Successful .NET 3.51 installFigure 5. Successful installation of .NET 3.51 by explicitly pointing to the source

Now when I run SQL Sever 2012’s Setup again, it reflects that .NET 3.51 is installed. I was able to get the instance installed and configured with no problems.

Ready to goFigure 6. .NET 3.51 installed – SQL Server should install just fine

So if you run into this issue with SQL Server 2012 and Windows Server 8, you’ll be able to fix it easily. Hope this helps some folks out there!