Moving Wordpress from Apache to IIS

Here are the full details of how I moved my blog from the Kiwihosting Unix servers to Windows, skipping all the missteps, so it’s more of a how I would redo it.

I was running 2.2.3 (as that was the latest version I could get working on the older server ) and I have WordPress located in the directory \blog on my domain.

  1. Download the full old site via FTP to local dir c:\temp\old

  2. Export Wordpress contents (in 2.2.3 Manage > Export) to (wordpress..xml)

  3. Check-out the current SVN WordPress trunk to c:\temp\wp-trunk
    note: I was having errors with release 2.6.3, so had to try 2.7-beta3

  4. Export trunk (c:\temp\wp-trunk) to c:\temp\wp27

  5. Copy c:\temp\oldroot to c:\temp\newroot

  6. Replace the *c:\temp\newroot\blog* directory with **c:\temp**wp27 contents

  7. Copy the Uploads *c:\temp\oldroot\blog\wp-content\uploads* to *c:\temp\newroot\blog\wp-content\uploads*

  8. Make a copy of the default theme, I did this just to simplify merging changes from SVN with my own changes.
    note: Change the header comment in c:\temp\newroot\blog\wp-content\themes\\style.css so you can tell the difference between your new theme and the default.

  9. Created domain in Helm

  10. Install the Propagation Support (Home > Domain > simeonpilgrim.com > Application Packs) to access site via a temporary URL

  11. Create DB, via Helm

  12. Create DB Users account, after step 11 you see the details on the connection string (with dummy values), notice that the box below has an Add User button, use that

  13. Configure wp-config.php to point to DB
    note: my database is on a non-standard port, so for the DB_HOST I added a port suffix so it looks like ‘server.name.com:3306’

  14. Create FTP User account

  15. Upload full site (*c:\temp\newroot*) to new server

  16. Install WordPress
    note: use the temporary URL as the WordPress address (URL) otherwise you will keep getting redirected to your old (and live) server. If you make this mistake you can log into myPhpAdmin (near bottom of left side bar) to edit the DB directly.

  17. Import WordPress contents wordpress..xml via Tools > Import

  18. Install Plugins

*   [WP-Mail-SMTP](http://www.callum-macdonald.com/code/wp-mail-smtp/) \- This is very important, as it allows WordPress to send email
    For kiwihost you just need to set **SMTP Host** to "localhost" and **Authentication** to "No: Do not use SMTP authentication."

*   [Google XML Sitemaps](http://www.arnebrachhold.de/redir/sitemap-home/ "Visit plugin homepage")

*   [Google Analytics for WordPress](http://yoast.com/wordpress/analytics/ "Visit plugin homepage")

*   [FD Feedburner Plugin](http://flagrantdisregard.com/feedburner/ "Visit plugin homepage")
  1. Fix Category slugs, any special character symbols get dropped when you import your old content, so for me the slugs for C# and C++ both became C, so I had to reassign the posts using those Categories

  2. Change permalink format and turn on URL rewriting so it works

  3. Change over DNS nameservers

  4. If you have the site perfect, change the URL (Settings > General > WordPress address (URL)), otherwise do this after the next step

  5. Wait a few days for DNS to roll-over

  6. Remove the Propagation Support from step 10

  7. Decommission old server and get 6 months free hosting for being so clever