Tuesday, May 3, 2011

Migrating MoinMoin 1.5.3 -> 1.9.3

How to migrate from moinmoin 1.5.3 (ie. old debian) to 1.9.3 (ie. new debian).

1) If you're using a farmconfig, in your wikis section if you have

"wikiname", "^wikiname.example.com/.*"
change it to
"wikiname", "^(http://)?wikiname.example.com/.*"

This makes the upgrade code match correctly (it incorrectly adds an http prefix to the url, despite saying it's not going to do so).

2) Update your underlay by going to your wiki's dir and doing:

rm -rf underlay
(cd /usr/share/moin ; tar cf - underlay | (cd /your/wiki/dir ; tar xf - ))

3) Provide metadata so the migration system can work. Go into your wiki's data/ dir and do

echo "data_format_revision: 1050300" >meta

4) Finally, run the migration by doing:

python2.5 /var/lib/python-support/python2.5/MoinMoin/script/moin.py --config-dir=/etc/moin --wiki-url=http://wikiname.example.com/ migration data

and then follow the directions it gives you. Note that after you rename rename1.txt to rename2.txt, the next step can take several minutes.

Worked for me, but YMMV.