I recently sold the web hosting client base of my company Asgard Web Technologies and have been shutting down the US servers where the clients were hosted. Since I have a whole bunch of my own sites plus look after a few for some friends I spent a while hunting around for a new hosting solution closer to home. Eventually I settled on leasing a Windows 2008 VPS from Tagadab, a new UK based dedicated server and VPS provider. So far things are running great and I’m very pleased with the service.

As always though, migrating websites to new servers can be challenging. In this case I was moving from IIS6 to IIS7 plus upgrading to the latest versions of PHP and MySQL. In addition, Asgard was using the Helm control panel for website management. The originally developers of Helm, WebHostAutomation, offered a free 5 client licence for Helm and this would have been ideal for maintaining my sites – but unfortunately Helm was bought out by Parallels and they’ve dropped this deal. While I could just maintain the sites through Windows, I liked the simplicity of a control panel and have decided to give DotNetPanel a go. DotNetPanel has a free 5 client licence!

DotNetPanel proved relatively easy to setup, though there was of course a learning curve . With PHP I was eager to test the new FastCGI capabilities of IIS7 and I found a great walkthrough on IIS.NET.  The first site I migrated was fittogether.eu, a new health based social network site based on Joomla we’re developing. It worked perfectly. I then migrated mlmfacts.net, a wiki I’m setting up to try and track all the different companies in the multi-level marketing world, and that’s where problems began – it simply wouldn’t work, complaining about not being able to load various “includes”. I then tried setting up a wordpress blog (this one!) at david.steadson.com and encountered almost the same issue.

After several hours of digging (and I’m not a PHP programmer) I eventually narrowed it down to a problem with the PHP function realpath() not providing the correct answer. I won’t go through the details here, you can read a bit about it on the iis.net forums where I reported the problem, but eventually I discovered the issue was actually with how DotNetPanel sets up websites. A site like this wordpress blog is installed in c:/HostingSpaces/David1/david.steadson.com/wwwroot. Various folders for logs and backups etc are placed in c:/HostingSpaces/David1/david.steadson.com. This isn’t a particular unusual setup, on Helm for example the site would have been in c:/HelmSites/david.steadson.com/wwwroot.

So what was the problem? Well, by default Helm gives access to the account folder, /david.steadson.com, to the user account the web service runs under. On a default IIS7 install folk tend to setup their sites under c:/inetpub and this directory also has read permissions for the web service. DotNetPanel on the other hand did not give this permission and I eventually found others who had reported similar problems. Adding the permission allowed the sites to work fine!

The only other “challenging” migration task was setting up “friendly URLs”. At Asgard we used a commercially IIS6 isapi module called isapi_rewrite that allowed websites to do URL rewriting using .htaccess and much the same syntax as used on *nix with mod_rewrite. This year though, Microsoft released a free IIS7 module, URL Rewrite, which does much the same thing, though with different syntax. Thankfully it comes complete with an “import” tool for importing mod_rewrite style rules and it’s working a charm.

So far I’ve migrated my various Amway hobby sites – www.amwaywatch.com, www.amwaytalk.com, www.thetruthaboutamway.com, and www.amwaywiki.com, next step is some of my other business sites and a handful of friends websites! I’ve requested Server Beach shutdown the server they’re on in the middle of next week, so I’m on a deadline ….