December 18, 2006 Update: You may find my post on .NET 3.0 compatibility useful.
As a part-time systems engineer, I was very concerned about possible negative effects of installing the .NET Framework 2.0 side-by-side with 1.1 on our Windows Server 2003 boxes that run things like SharePoint Portal Server, Windows SharePoint Services and Exchange 2003. I’ve searched and searched, and it seems like Microsoft is making little effort to document .NET Framework 2.0 compatibility with their server products.
It helps to understand how different types of executable code load the Framework. Unmanaged applications that host the Common Language Runtime (CLR), that is, non-.NET applications that manually load the CLR in order to run .NET code, always load the newest installed version of the .NET Framework by default. This behavior directly impacts SharePoint Portal Server, as one example, in a negative way. Some unmanaged executables in SPS host the CLR, so as soon as you install 2.0 and restart the SPS apps, they will load 2.0, not 1.1 as they were designed and tested against. BAD!
Fortunately, managed applications behave better. A managed application that was built against 1.1 will continue to load 1.1, as long as 1.1 is installed. (On Windows Server 2003 you don’t have a choice, but on other OS’s you can uninstall 1.1.) A managed application that was built against 2.0 will only load 2.0. If you uninstall Framework 1.1, your 1.1 managed app will now load 2.0 instead.
Confused? When Microsoft doesn’t document which unmanaged apps host the CLR, the bottom line is that you need to be careful installing 2.0.
If you identify an unmanaged app that hosts the 1.1 CLR and you want to install Framework 2.0, there is a way to force the unmanaged app to load the old Framework:
- Locate the unmanaged EXE, and in the same directory, create (or edit) a text file called <unmanagedexename>.exe.config. Ex: myapp.exe needs myapp.exe.config.
- Paste this text into the new text file (or merge it into the existing file; you may already have <configuration> and/or <startup> elements):
<?xml version =”1.0″?>
<supportedRuntime version=”v1.1.4322″ />
- Save the config file and start or restart the EXE or service
Installing the 2.0 Framework without adding or updating the config files will affect SharePoint Portal Server and BizTalk Server 2004. BizTalk Server 2006 natively runs on, and requires, .NET Framework 2.0, and runs just fine with .NET Framework 3.0 as well.
To safely install 2.0 on your BizTalk 2004 server:
- Add (or update) a config file for each EXE in your BizTalk 2004 installation folder
- Reboot or restart all BizTalk services
- Review Microsoft’s KB
- After installing Framework 2.0, ensure that all BizTalk Web services remain configured to run under ASP.NET 1.1.
To safely install 2.0 on your SPS servers:
- Add (or update) a config file for each EXE in your SPS installation folder
- I recommend installing WSS 2.0 SP2, which explicitly supports ASP.NET 2.0, and then SPS 2003 SP2. If you are not ready to upgrade, you can still add the config files and safely install 2.0 on SP1 or earlier.
- After installing Framework 2.0, ensure that all SPS portal Web sites remain configured to run under ASP.NET 1.1. SPS SP2 does not support ASP.NET 2.0, even though WSS does.
To safely install 2.0 on your Exchange 2003 servers:
- Exchange Server 2003 doesn’t appear to host the CLR, so it should be safe to install 2.0 on Exchange front-end or back-end servers. I installed it on our front-end server with no issues.
- After installing Framework 2.0, ensure that the OWA Web site remains configured to run under ASP.NET 1.1 (IIS Admin, site properties, ASP.NET tab).
Installing .NET Framework 2.0 installs ASP.NET 2.0. By default, this will not change existing IIS Web sites to 2.0 — they will remain set to 1.1/1.0. You can control this in IIS Admin in the site properties under the new ASP.NET tab. Do not try to mix ASP.NET 1.1 and 2.0 apps within a single AppPool on Windows Server 2003. Create separate AppPools for each version.
Office 2003 is unmanaged but does host the CLR, so it may also be affected by installing Framework 2.0. There are known issues with Office 2003 when loading add-ins, smart tags or smart documents created with .NET Framework 2.0. There is also a related VS2005 update for Visual Studio 2005 developers.
Visual Studio .NET 2003 developers may experience trouble in certain cases after installing Framework 2.0. One such issue is fixed in .NET Framework 1.1 SP2.
The Framework documentation briefly, and poorly, discusses the side-by-side issue here.
I would appreciate comments on this post! Is it helpful? What information can I expand on? Are there other issues that you are concerned about or have experienced?