RedBits My Ass
One of the small neglected features of what’s been happening with .NET 3.5 recently is the whole mess surrounding what’s collectively referred to by Microsoft RedBits vs. GreenBits.
What provoked me into writing about this in this blog is that Microsoft bit me in the ass (or screwed me, depending on your preferences I guess) and got my machine into a situation that while .NET 3.5 redist WAS installed (presumably), it really wasn’t. Sounds funny innit?
It appears (after spending almost a full day trying to drill this down) that to get a full working version of .NET 3.5 it is might not be enough to have an install of the .NET 3.5 redist…
Daniel Moth for MS gives a nice theoretical explanation about this in his blog:
Too bad it doesn’t actually contain enough information. and too bad that MS has a crappy package management system which is capable of bringing a working machine into a “in-limbo” situation. Hey MS, here’s a pointer on how to make a package management system: http://en.wikipedia.org/wiki/Advanced_Packaging_Tool
The problem is that in reality the .NET 3.5 is made up of two separate parts… One is the .NET 3.5 redist, and the other is .NET 2.0/3.0 SP1.
This is actually depicted in the picture above… The “red” circles around the .NET 2.0 and 3.0 yellow ellipses denote the “RedBits” or the additional updates that need to be installed in .NET 2.0 and 3.0 independantly (!) before installing .NET 3.5.
As you can see, certain new APIs in MSDN, like Socket.SendAsync, are fully supported in .NET 2.0 SP1, even if you don’t have .NET 3.5 installed.
This kind of makes some technical sense as the SP1 update is downloadable for x86 / x64, as well as a .NET 3.0 SP1 (which appears to be architecture independent…) as a separate update from Microsoft…
Unfortunately there is not easy way of downloading the same update for Vista. The only way I was able to get it is by getting the VS 2008 DVD and looking for the updates in:
One might be left with the logical question: Why the duality Microsoft? Why just not call the whole thing .NET 3.5 AND (notice the logical and: && operator in my statement) distribute it as one downloadable update?
I have no idea what drove Microsoft into the insanity of splitting this up into two different updates, especially since this now means that when using VS 2008 to target the .NET Framework 2.0 in the build properties you are actually targeting .NET 2.0 SP1 (which is not clearly stated anywhere except for reality).
Now, Why should I care about this, apart from it being technically ludicrous?
The reason is simple. Microsoft bit me in the ass (or screwed me, depending ob your gender I guess) and got my machine into a situation that while .NET 3.5 redist WAS installed (presumably), the .NET 2.0 SP1 / .NET 3.0 SP1 were not…
Think I’m lying? take a look at these two pictures taken with Lutz Roeder’s Reflector:
This is .NET 3.5 installed WITHOUT the 2.0 / 3.0 SP1:
This is .NET 3.5 installed AFTER FIXING THIS ISSUE:
Note that in both screenshots you can see that the System.Core assembly is installed properly, while the versipn and size information for System.dll is distinctly different….
If you’re wondering how I got to this amazing situation… That’s simple… The answer is Vista SP1. Apparently, when you uninstall the Vista SP1 it also uninstalls he .NET 2.0 /3.0 SP1 packages… while leaving the 3.5 seemingly intact! (Stupid! Stupid! Stupid!) Has anyone in redmond not heard of dependencies and reference counting? Are you all too busy doing something other than releasing dependable software (pun intended)?
If you’re wondering how I finally did understand what was going on… It was by uninstalling the 3.5 that I seemingly had installed… and then trying to re-install it. This immediately led me into a situation where .NET 3.5 refused to install without having a 2.0 / 3.0 SP1 installed (not that the installer actually said something along those lines, I naturally had to go through the installation log files to get the valuable piece of information)…