I’m installing a new hard drive on my notebook today. I'm going to post the process I went through here, because for once this process went pretty smooth and I ended up with everything intact on the other end. Maybe this helps out somebody, and more importantly maybe I will read this the next I need to go through this excercise .
My machine was starting to get dog slow as the old hard drive was reaching capacity – it’s also been over two years since the last full Windows install on this machine. Add to that various installs of Whidbey (sans VPC) and it’s no wonder this machine has been getting slow. So it’s time to do a fresh start. I decided to buy a faster and somewhat bigger hard drive and of first blush it’s noticeably more snappy. Of course this could be just the new install.
This has been the first time I’ve done an organized install. Usually it’s just like do a backup of some sort and then hope for the best. This time around I wanted to plan things out a little better and while at it build up a clean drive image that I can restore to if there will be another re-install of this system.
I actually started the whole process a couple of days ago. The first thing I did is create a full backup image of my current drive with True Image (which I finally got to work with some, uh, trickery that I can’t talk about ). The product actually works amazingly well as it is fast and very efficient in backing up the hard disks. It created a 15 gig image from 55 gigs of used space in about a half an hour! I backed up the whole thing onto an external Firewire drive I got a few weeks ago.
Next I swapped drives and did the initial install of Windows 2003 server on the new drive on my laptop. I like to time this stuff while I’m off doing something else, like fixing dinner or watching a movie or whatever and then just check in every once in a while to get past the prompts.
The install went smoothly except that the none of the Dell network cards where detected and of course I couldn’t remember where the drivers where at. So I had to uninstall the drive and boot into the other one and download the various drivers.
I did have a few problems with the ATI drivers which blue screened Windows a couple of times for the first two boot cycles – always a fun experience. I remember this from my last install. What’s funny is that this was without hardware acceleration enabled. When I came back in I turned acceleration to Full and the crashing stopped. Go figure. The wireless Dell True Mobile card also is hiccing up a bit – it doesn’t want to get onto my wireless net here, but it’s seeing the network. It just fails to authenticate even though I went and checked the old settings. Oddly enough it gets assigned the inbound ISP IP address rather than than a DHCP address. I’m not quite sure what to make of that. For now the wired connection works.
Once the hardware’s ready, IIS gets installed. Next I went ahead and installed Office, VS.NET, Visual FoxPro, SQL Server + SP3 and a bunch of utilities like SnagIt, FileZilla, FireFox, MusicMatch (8.1 definitely not 10) etc. I also installed True Image and pulled a few more of the generic utilities off the True Image backup. Again True Image works beautifully for this – it simply maps the backup drives as mounted drive lettered drives so you can simply brows them with Explorer. And it’s fast! For most things it feels like a slightly sluggish hard disk pulling stuff out of the compressed backup.
Anyway the idea is to install all the baseline stuff before any of the application data and code related stuff onto the machine and then back up the baseline for re-use should I end up having to do another reinstall before the notebook expires (not likely the machine is 2.5 years old – but I don’t see a reason to get a newer machine that will be only marginally faster).
So then I created a new True Image backup that I was hoping would be small enough to fit on a DVD – and it was just under 4.3gig, containing all the stuff just installed. This now has become a new install baseline should I have to reinstall and it all fits onto a DVD I can pack and take with me! Between that baseline plus a common weekly or more frequent DVD backup of my work data I should be able to get a new system up an running in an hour or so in the future (which is handy if you’ve ever had the pleasure of crashing a machine on the road the night before a conference session ).
All of this had taken a few hours so far spread over the course of a day with swapping hard drives a couple of times, so I could go on working and getting mail etc.
Finally it was time to do a final backup of all the work data. This is actually crucial and here is where I really need to remember a few things and do it right.
Detach all the SQL Server Databases that I care about, so you can easily re-attach them. Actually I decided to move all my actual used SQL Server databases into a single directory first then detached them all. I’m not sure if there’s an easier way, but this seems pretty efficient and certainly easier than doing backups and restoring.
Make sure to stop SQL Server and IIS to minimize any locked files. We want to make sure the back up succeeds on all files.
Do a backup of the Office settings and store to a disk file. Office has a Wizard that exports all settings to a file. For me this is crucial because I use my Outlook.pst file in a private folder rather than Outlooks default location. Getting outlook to move the default PST requires mucking with the registry which I can never remember.
Finally it’s time to do the final backup with True Image. 10 minutes of backup, reboot, swap drives and it’s off to installation mania.
Now the fun really starts, which is installing all the application data. Surprisingly with the scheme I’ve used this all went very smooth. I copied all the data and code and project directories back onto the drive. Unlike Microsoft recommendations I don’t store any of my data under MyDocuments but I use a set of folders underneath the root for everything. So all my VS work sits under Projects, all the Fox stuff under wwApps, all data like Quickbooks, the SQL Server databases for my internal apps under data, all writing stuff under articles and so on. This sure is a lot easier and more consistent than trying to peel this stuff out from My Documents and the hell that gets created there by various programs.
Copying the data out from True Image takes about 20 minutes – again impressive for probably 40 gig of data. Next run Enterprise manager and reattach all the databases. Piece of cake… Run the Office Restore My Settings Wizard. Start Outlook and voila my folders are all active and working – even the news feeds are there even though NewsGator isn’t installed yet.
Next come some of my internal apps. All of the .NET apps fire right up. No hassles at all – they find the database and just work. I was a little worried about things like ActiveReports and Sandbar but I forgot that I actually always deploy these with each app, so all of that just works without any new configuration.
The Fox apps (Help Builder in particular) cough a little because some of the ActiveX controls aren’t installed. I manually register the 2 controls which I use in just about all of my apps and life is good there as well. I could have also run a reinstall but since my builds are dev builds this is a little messy.
Because the pathing is the same with both installs everything just works in place which is very cool!
Finally - setting up and configuring all the Web apps. The problem here is that when you move your site you loose all the virtual directory configurations, your app pools all that stuff. Of course, I forgot to back that up - I've never actually tried this though I should have simply backed up the settings on the old drive and then move them over to the new machine.
For ASP.NET I had to manually run aspnet_regiis.exe. For some reason the .NET installation didn't register IIS even though it was installed. I think it's because I changed the IIS home directory after the fact, but I can't remember now. It's pretty obvious that ASP.NET is not installed if you can find the ASP.NET entry on the Web Extensions page in IIS 6.
Instead I decided that it might be a good idea to start fresh. I've noticed that a few apps like ASP.NET Version switcher had problems reading my site, probably because I do so many installs and uninstalls of Web sites for testing various scenarios with the Web Store, Web Connection and the various ASP.NET articles I put together. Just yesterday I must have done about 40 installs uninstalls while testing the various Web Connection versions. <g> Anyway I decided to do this manually or semi manually. THe job is pretty easy by simply going in and re-creating the directories as virtual 'applications'. The more tedious part is reconfiguring any additional script maps and more importantly remembering which ones require script maps.
Finally one more hiccup when testing my apps for the first time - the ASP.NET state service didn't automatically start up, which makes sense I guess. Ah all those little details.
Phew, I'm sure I'll be spending a bit of time the first time I run each of my Web apps making sure everything works, but it'll be minor.
Phew, I think the core stuff is done. Now it's just installing the odd program I forgot here or there and configuring a few additional features etc.
As I said, I’ve done a lot of these types of upgrades before and it’s never gone this smooth. The fact that I could so painfully backup the old drive and access its content easily is a huge help and relieves the stress level tremendously.
But, even with all of this preparation and ‘stepped’ install, it’s taken a good solid day of time to get even this far - when it's all said and done it'll probably closer to a a day and a half. Most of the obvious stuff is installed now, but there are all the little tools and utilities and plug-ins that need to be reinstalled. Lookout, Google Toolbar, Fiddler, etc. etc. there are just too many things to remember. The ActiveBar control environment. ActiveReports add-in stuff. etc. etc. etc.
I'll be installing tons of stuff over the next week I'm sure. But the core stuff is there!
Thank god for the Internet. There are so many things that I don’t have the install sitting around for – it’d be an absolute nightmare if you didn’t have easy access to the Internet to download drivers and utilities quickly.