Jump to content

Topic on Project:Support desk

Best way to migrate (1.14 -> 1.21) to a new server and new version at the same time?

5
193.2.84.34 (talkcontribs)

Hi,

we use MediaWiki on IIS6.0 windows server, PHP 5.2.0 and MySQL 5.0.45. We have a 500 page wiki, just text, 200 users.

What is the best way to migrate to a new server: we would like to set up a new IIS 7.0 windows server, MediaWiki 1.21. What PHP do you recommend? What MySQL do you recommend?

Plan: install new server, install new MediaWiki with new php and mysql. Export pages from old MediaWiki, import pages to new MediaWiki. Is it possible? Recommended? We don't need page history, we don't even need discussion pages. we don't even need users, but would like to import/export them if possible.


Thanks for the advice...

88.130.100.168 (talkcontribs)

Hi!

If you want to update to MediaWiki 1.21 (directly now are after switching to the new server), you should use PHP 5.3. For MySQL I would choose MySQL 5.5. 5.1 would work as well, but 5.5 will be supported longer (and if you already have 5.5, you will not have to do an update to 5.5 in the future).

I don't know how well importing/exporting pages from and to MediaWiki works. I would have done a "usual" update: Exchange the MediaWiki source code and then run update.php.

My plan would be this

  • Install server, PHP, MySQL. Check that all settings are OK for MediaWiki, e.g. safe_mode off, memory limit OK, write permissions for the server set properly - most of these things should already be set up correctly on your old server; you can use that one to compare and check.
  • Copy over all files of the old version of MediaWiki.
  • Take a mysldump of your database from the old server and import it using mysql on the new server.
    • Update database credentials in LocalSettings.php.
    • At that point MediaWiki is installed completely; however, due to the changed PHP version it might be that MediaWiki does not work correctly, because it still is the old version.
  • Do the upgrade to MediaWiki 1.21 as described here Upgrade.
  • Go, seat yourself in the freezer and relax (it is 35°C here and it feels like 50).

This post was posted by 88.130.100.168, but signed as 88.130.69.74.

193.2.84.34 (talkcontribs)

Hmmm, interesting. Why not setting up MediaWiki 1.21 on a new server and then importing mysql dump of the old database? Thanks It is 35 here and air condition is a bless.

MarkAHershberger (talkcontribs)

You could:

  1. unzip 1.21 on the new server
  2. copy LocalSettings.php and the images directory from the old server
  3. update the DB settings in the LocalSettings.php
  4. import the DB from the old server to the new server
  5. run update.php on the new server

If you export and import pages, that will take longer than exporting and importing the database and you'll lose user information.

88.130.100.168 (talkcontribs)

It does not really matter: You can also set up a new MW 1.21 install on the new server as Mark said. In Mark's first step, you should not only copy over your LocalSettings.php file and the folder images/, but also extensions/ (if you used any; don't forget that there might be newer versions to update to) and the folder skins/, if you had modified a skin or created your own skin.

Reply to "Best way to migrate (1.14 -> 1.21) to a new server and new version at the same time?"