collective.migrator

by Suresh V last modified Feb 16, 2011 02:06 AM

Tool and buildout recipes for zope/plone content migration

Project Description

collective.migrator is a buildout based tool to help migrate content between Plone/Zope instances. It can be installed as follows:

$ easy_install  collective.migrator

Once installed you can run the tool to set up the migration environment

$ migrator

This creates a folder called migrator and installs a buildout environment there. All further actions are run from this folder.

The first thing that you want to do at this point is customize the instance.cfg file.

By default it looks like this:

[remote]
host = xxx.webfactional.com
user = ssh_user
port = 8080
extensions = /usr/Plone-2.5.5/zeocluster/client1/Extensions
zmi_user = admin
zmi_pwd = admin
root = Plone
export = /usr/Plone-2.5.5/zeocluster/client1/var

[local]
host = localhost
port = 8080
extensions = /home/suresh/plone4/parts/instance/Extensions
zmi_user = admin
zmi_pwd = admin
root = Plone
import = /home/suresh/plone4/var/instance/import

This defines the settings for all the Plone instances involved in the migration.

The buildout.cfg defines the steps that will be executed as part of the migration.

Here is the default content:

[buildout]
extends = instance.cfg
migrate_frontpage.cfg
migrate_users.cfg
migrate_props.cfg
parts =
tbd =
${migrate_frontpage:parts}
${migrate_users:parts}
${migrate_props:parts}

As you can see, parts has been intentionally left blank. Also instance.cfg described previously is being used here. The other migrate_.cfg* files contain some sample steps to move various objects between the instances.

As a simple test, you can change parts in buildout.cfg to look like this:

parts = export_frontpage

This step is defined in migrate_frontpage.cfg.

Now after you run buildout as follows:

$ bin/buildout

you should notice that the front-page object has been exported in the remote Plone instance. Once you gain more confidence in the tool, you can even try to run the other steps found in the migrate_.cfg* files.

PS: This may not be the "coolest" way to manipulate your Plone and some of these actions may be better done with GenericSetup profiles, but this worked for me!

Current Release
collective.migrator 1.8

Released Feb 22, 2012 — tested with Plone 4.1, Plone 4, Plone 3, Plone 2.5

more improvements and recipes
More about this release…

If you are using Plone 3.2 or higher, you probably want to install this product with buildout. See our tutorial on installing add-on products with buildout for more information.

All Releases

Version Released Description Compatibility Licenses Status
1.8 Feb 22, 2012 more improvements and recipes More about this release…
Plone 4.1
Plone 4
Plone 3
Plone 2.5
GPL final
1.6 Feb 26, 2011 See full release description More about this release…
Plone 4
Plone 3
Plone 2.5
Plone 2.1
Plone 2.0
GPL final
1.4 Nov 27, 2010 Fixed some bugs, added documentation especially around installation and clean ups More about this release…
Plone 4
Plone 3
Plone 2.5
Plone 2.1
Plone 2.0
GPL final
1.2 Aug 11, 2010 Several improvements and new scripts More about this release…
Plone 4
Plone 3
Plone 2.5
GPL final
1.0 Jul 05, 2010 Initial release More about this release…
Plone 4
Plone 3
Plone 2.5
Plone 2.1
Plone 2.0
Plone 1.0
GPL final