Hi,
We had a consulting partner who did the same for our company. This is his procedure and worked great:
How to migrate ovirt management engine
Packages
Ensure you have the same packages & versions installed on the destination hostas on the source, using 'rpm -qa | grep ovirt'. Make sure versions are 100%identical.
Default setup
Run 'engine-setup' on the destination host after installing the packages. Use
the following configuration:
1. Backup existing configuration
2. On the source host, do:
a. service ovirt-engine stop
b. service ovirt-engine-dwhd stop
c. mkdir ~/backup
d. tar -C /etc/pki/ovirt-engine -czpf ~/backup/ovirt-engine-pki.tar.gz .
e. tar -C /etc/ovirt-engine -czpf ~/backup/ovirt-engine-conf.tar.gz .
f. cd /usr/share/ovirt-engine/dbscripts
g. ./backup.sh
h. mv engine_*.sql ~/backup/engine.sql
3. You may also want to backup dwh & reports:
a. cd /usr/share/ovirt-engine/bin/
b. ./engine-backup.sh --mode=backup --scope=db --db-user=engine --db-password=XXX --file=/usr/tmp/rhevm-backups/engine-backup --log=/tmp/engine-backup.log
c. ./engine-backup.sh --mode=backup --scope=dwhdb --db-user=engine --db-password=XXX --file=/usr/tmp/rhevm-backups/dwh-backup --log=/tmp/engine-backup.log
d. ./engine-backup.sh --mode=backup --scope=reportsdb --db-user=engine --db-password=XXX --file=/usr/tmp/rhevm-backups/reports-backup --log=/tmp/engine-backup.log
4. Download these backup files, and copy them to the destination host.
Restore configuration
1. On the destination host, do:
a. service ovirt-engine stop
b. service ovirt-engine-dwhd stop
c. cd backup
d. tar -C /etc/pki/ovirt-engine -xzpf ovirt-engine-pki.tar.gz
e. tar -C /etc/ovirt-engine -xzpf ovirt-engine-conf.tar.gz
f. tar -xvjf engine-backup
g. tar -xvjf dwh-backup
h. tar -xvjf reports-backup
Restore Database
1. On the destination host do:
a. su - postgres -c "psql -d template1 -c 'drop database engine;'"
b. su - postgres -c "psql -d template1 -c 'create database engine owner engine;'"
c. su - postgres
d. psql
e. \c engine
f. \i /path/to/backup/engine.sql
NOTE: in case you have issues logging in to the database, add the following
line to the pg_hba.conf file:
host all engine
127.0.0.1/32 trust
2. Fix engine password:
a. su - postgres
b. psql
c. alter user engine with password 'XXXXXXX';
Change ovirt hostname
On the destination host, run:
/usr/share/ovirt-engine/setup/bin/ovirt-engine-rename
NB:
Restoring the dwh/reports database is similar to steps 5-7, but omitted from
this document due to problems starting the reporting service.