1.1 --- a/docs/wiki/Administration Fri Apr 22 15:03:43 2016 +0200
1.2 +++ b/docs/wiki/Administration Fri Apr 22 15:26:27 2016 +0200
1.3 @@ -131,3 +131,38 @@
1.4 use of this tool will be performed by the packaging system provided by an
1.5 operating system distribution. The `tools/install.sh` script runs the above
1.6 tool as part of the installation process.
1.7 +
1.8 +== Copying Stores and Changing Store Types ==
1.9 +
1.10 +A rudimentary tool is provided that can copy data between stores, even those of
1.11 +different types, thus allowing the migration of data from one kind of store to
1.12 +another. Although it does not perform the copying in the most efficient manner,
1.13 +it provides a convenient method of copying that uses the software's own general
1.14 +interfaces for store access and thus acts as a way of verifying that these are
1.15 +functioning correctly.
1.16 +
1.17 +To copy a configured store to another filesystem location:
1.18 +
1.19 +{{{
1.20 +tools/copy_store.py -t file /tmp/store /tmp/journal
1.21 +}}}
1.22 +
1.23 +To copy a configured store to a database (which must have been initialised):
1.24 +
1.25 +{{{
1.26 +tools/copy_store.py -t postgresql 'dbname=store' 'dbname=journal'
1.27 +}}}
1.28 +
1.29 +To copy an explicitly-specified file store to another filesystem location:
1.30 +
1.31 +{{{
1.32 +tools/copy_store.py \
1.33 + -f file /var/lib/imip-agent/store /var/lib/imip-agent/journal \
1.34 + -t file /tmp/store /tmp/journal
1.35 +}}}
1.36 +
1.37 +The help message for the tool provides general guidance for its use:
1.38 +
1.39 +{{{
1.40 +tools/copy_store.py --help
1.41 +}}}