[ovirt-users] Re: fail to restore ovirt-engine
Thank you, > oVirt version is: oVirt Node 4.2.5.1 > I manage to fix it with as follow: 1. > >engine-cleanup 2. > >su - postgres export > LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/rh/rh-postgresql95/root/usr/lib64/ > scl enable rh-postgresql95 -- psql > alter role engine superuser; #(I know it's not good, but I don't care) > \q > 1. restart the machine 2. engine-backup --mode=restore --file=backup --log=restore5.log --restore-permissions --provision-all-databases # 1. it failed with the following error but the database was created, 2. > > pg_restore: [archiver (db)] Error while PROCESSING TOC: > pg_restore: [archiver (db)] Error from TOC entry 710; 1255 174984 > FUNCTION uuid_generate_v1() engine > pg_restore: [archiver (db)] could not execute query: ERROR: > function "uuid_generate_v1" already exists with same argument types > Command was: CREATE FUNCTION uuid_generate_v1() RETURNS uuid > LANGUAGE plpgsql STABLE > AS ' > DECLARE > v_val BIGINT; > v_4_1_par... > pg_restore: WARNING: column "user_role_title" has type "unknown" > DETAIL: Proceeding with relation creation anyway. > WARNING: errors ignored on restore: 1 > 2019-01-02 04:28:22 28664: FATAL: Errors while restoring database > engine > 3. > >engine-backup --mode=restore --file=backup --log=restore6.log >--scope=files --no-restore-permissions # (this was sucessed ) > 4. restart machine 5. engine-setup (and replay y to fix the database) this was a very long night, but ended with great success!! hope it helps. On Wed, Jan 2, 2019 at 9:38 AM Yedidyah Bar David wrote: > On Wed, Jan 2, 2019 at 3:45 AM maoz zadok wrote: > > > > I really need help here... please!! > > my engine was crashed, I have backups, but the restore failed. > > > > engine-backup --mode=restore --file=backup --log=restore.log > --provision-all-databases --restore-permissions > > > > this is the log: > > 2019-01-02 03:39:22 13186: Start of engine-backup mode restore scope all > file backup > > 2019-01-02 03:39:22 13186: Setting scl env for rh-postgresql95 > > 2019-01-02 03:39:22 13186: OUTPUT: Preparing to restore: > > 2019-01-02 03:39:22 13186: OUTPUT: - Unpacking file 'backup' > > 2019-01-02 03:39:22 13186: Opening tarball backup to > /tmp/engine-backup.bGOLRNXeD4 > > 2019-01-02 03:39:22 13186: Verifying md5 > > 2019-01-02 03:39:22 13186: Verifying version > > 2019-01-02 03:39:22 13186: Reading config > > 2019-01-02 03:39:22 13186: OUTPUT: Restoring: > > 2019-01-02 03:39:22 13186: OUTPUT: - Files > > 2019-01-02 03:39:22 13186: Restoring files > > 2019-01-02 03:39:22 13186: Reloading configuration > > 2019-01-02 03:39:22 13186: OUTPUT: Provisioning PostgreSQL > users/databases: > > 2019-01-02 03:39:22 13186: provisionDB: user engine host localhost port > 5432 database engine secured False secured_host_validation False > > 2019-01-02 03:39:22 13186: OUTPUT: - user 'engine', database 'engine' > > [ INFO ] Stage: Initializing > > [ INFO ] Stage: Environment setup > > Configuration files: > ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', > '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', > '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf', > '/tmp/engine-backup.bGOLRNXeD4/pg-provision-answer-file'] > > Log file: > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log > > Version: otopi-1.7.8 (otopi-1.7.8-1.el7) > > [ INFO ] Stage: Environment packages setup > > [ INFO ] Stage: Programs detection > > [ INFO ] Stage: Environment customization > > [ INFO ] Stage: Setup validation > > [WARNING] Cannot validate host name settings, reason: resolved host does > not match any of the local addresses > > [ INFO ] Stage: Transaction setup > > [ INFO ] Stage: Misc configuration > > [ INFO ] Stage: Package installation > > [ INFO ] Stage: Misc configuration > > [ INFO ] Creating PostgreSQL 'engine' database > > [ INFO ] Configuring PostgreSQL > > [ INFO ] Stage: Transaction commit > > [ INFO ] Stage: Closing up > > [ INFO ] Stage: Clean up > > Log file is located at > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log > > [ INFO ] Stage: Pre-termination > > [ INFO ] Stage: Termination > > [ INFO ] Execution of provisiondb completed successfully > > 2019-01-02 03:39:28 13186: provisionDB: user ovirt_engine_history host > localhost port 5432 database ovirt_engine_history secured False > secured_host_validation False > > 2019-01-02 03:39:28 13186: OUTPUT: - user 'ovirt_engine_history', > database 'ovirt_engine_history' > > [ INFO ] Stage: Initializing > > [ INFO ] Stage: Environment setup > > Configuration files: > ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', > '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', >
[ovirt-users] Re: fail to restore ovirt-engine
On Wed, Jan 2, 2019 at 3:45 AM maoz zadok wrote: > > I really need help here... please!! > my engine was crashed, I have backups, but the restore failed. > > engine-backup --mode=restore --file=backup --log=restore.log > --provision-all-databases --restore-permissions > > this is the log: > 2019-01-02 03:39:22 13186: Start of engine-backup mode restore scope all file > backup > 2019-01-02 03:39:22 13186: Setting scl env for rh-postgresql95 > 2019-01-02 03:39:22 13186: OUTPUT: Preparing to restore: > 2019-01-02 03:39:22 13186: OUTPUT: - Unpacking file 'backup' > 2019-01-02 03:39:22 13186: Opening tarball backup to > /tmp/engine-backup.bGOLRNXeD4 > 2019-01-02 03:39:22 13186: Verifying md5 > 2019-01-02 03:39:22 13186: Verifying version > 2019-01-02 03:39:22 13186: Reading config > 2019-01-02 03:39:22 13186: OUTPUT: Restoring: > 2019-01-02 03:39:22 13186: OUTPUT: - Files > 2019-01-02 03:39:22 13186: Restoring files > 2019-01-02 03:39:22 13186: Reloading configuration > 2019-01-02 03:39:22 13186: OUTPUT: Provisioning PostgreSQL users/databases: > 2019-01-02 03:39:22 13186: provisionDB: user engine host localhost port 5432 > database engine secured False secured_host_validation False > 2019-01-02 03:39:22 13186: OUTPUT: - user 'engine', database 'engine' > [ INFO ] Stage: Initializing > [ INFO ] Stage: Environment setup > Configuration files: > ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', > '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', > '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf', > '/tmp/engine-backup.bGOLRNXeD4/pg-provision-answer-file'] > Log file: > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log > Version: otopi-1.7.8 (otopi-1.7.8-1.el7) > [ INFO ] Stage: Environment packages setup > [ INFO ] Stage: Programs detection > [ INFO ] Stage: Environment customization > [ INFO ] Stage: Setup validation > [WARNING] Cannot validate host name settings, reason: resolved host does not > match any of the local addresses > [ INFO ] Stage: Transaction setup > [ INFO ] Stage: Misc configuration > [ INFO ] Stage: Package installation > [ INFO ] Stage: Misc configuration > [ INFO ] Creating PostgreSQL 'engine' database > [ INFO ] Configuring PostgreSQL > [ INFO ] Stage: Transaction commit > [ INFO ] Stage: Closing up > [ INFO ] Stage: Clean up > Log file is located at > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log > [ INFO ] Stage: Pre-termination > [ INFO ] Stage: Termination > [ INFO ] Execution of provisiondb completed successfully > 2019-01-02 03:39:28 13186: provisionDB: user ovirt_engine_history host > localhost port 5432 database ovirt_engine_history secured False > secured_host_validation False > 2019-01-02 03:39:28 13186: OUTPUT: - user 'ovirt_engine_history', database > 'ovirt_engine_history' > [ INFO ] Stage: Initializing > [ INFO ] Stage: Environment setup > Configuration files: > ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', > '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', > '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf', > '/tmp/engine-backup.bGOLRNXeD4/pg-provision-answer-file'] > Log file: > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033928-nit1oc.log > Version: otopi-1.7.8 (otopi-1.7.8-1.el7) > [ INFO ] Stage: Environment packages setup > [ INFO ] Stage: Programs detection > [ INFO ] Stage: Environment customization > [ INFO ] Stage: Setup validation > [WARNING] Cannot validate host name settings, reason: resolved host does not > match any of the local addresses > [ INFO ] Stage: Transaction setup > [ INFO ] Stage: Misc configuration > [ INFO ] Stage: Package installation > [ INFO ] Stage: Misc configuration > [ INFO ] Creating PostgreSQL 'ovirt_engine_history' database > [ INFO ] Configuring PostgreSQL > [ INFO ] Stage: Transaction commit > [ INFO ] Stage: Closing up > [ INFO ] Stage: Clean up > Log file is located at > /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033928-nit1oc.log > [ INFO ] Stage: Pre-termination > [ INFO ] Stage: Termination > [ INFO ] Execution of provisiondb completed successfully > 2019-01-02 03:39:34 13186: OUTPUT: Restoring: > 2019-01-02 03:39:34 13186: Generating pgpass > 2019-01-02 03:39:34 13186: Verifying connection > 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U engine -h localhost -p > 5432 engine -c select 1 > ?column? > -- > 1 > (1 row) > > 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U engine -h localhost -p > 5432 engine -t -c show lc_messages > 2019-01-02 03:39:34 13186: pg_cmd running: pg_dump -w -U engine -h localhost > -p 5432 engine -s > 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U ovirt_engine_history -h > localhost -p 5432 ovirt_engine_history -c select 1 > ?column? > -- > 1 > (1 row) > > 2019-01-02
[ovirt-users] Re: fail to restore ovirt-engine
I really need help here... please!! my engine was crashed, I have backups, but the restore failed. engine-backup --mode=restore --file=backup --log=restore.log --provision-all-databases --restore-permissions this is the log: 2019-01-02 03:39:22 13186: Start of engine-backup mode restore scope all file backup 2019-01-02 03:39:22 13186: Setting scl env for rh-postgresql95 2019-01-02 03:39:22 13186: OUTPUT: Preparing to restore: 2019-01-02 03:39:22 13186: OUTPUT: - Unpacking file 'backup' 2019-01-02 03:39:22 13186: Opening tarball backup to /tmp/engine-backup.bGOLRNXeD4 2019-01-02 03:39:22 13186: Verifying md5 2019-01-02 03:39:22 13186: Verifying version 2019-01-02 03:39:22 13186: Reading config 2019-01-02 03:39:22 13186: OUTPUT: Restoring: 2019-01-02 03:39:22 13186: OUTPUT: - Files 2019-01-02 03:39:22 13186: Restoring files 2019-01-02 03:39:22 13186: Reloading configuration 2019-01-02 03:39:22 13186: OUTPUT: Provisioning PostgreSQL users/databases: 2019-01-02 03:39:22 13186: provisionDB: user engine host localhost port 5432 database engine secured False secured_host_validation False 2019-01-02 03:39:22 13186: OUTPUT: - user 'engine', database 'engine' [ INFO ] Stage: Initializing [ INFO ] Stage: Environment setup Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf', '/tmp/engine-backup.bGOLRNXeD4/pg-provision-answer-file'] Log file: /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log Version: otopi-1.7.8 (otopi-1.7.8-1.el7) [ INFO ] Stage: Environment packages setup [ INFO ] Stage: Programs detection [ INFO ] Stage: Environment customization [ INFO ] Stage: Setup validation [WARNING] Cannot validate host name settings, reason: resolved host does not match any of the local addresses [ INFO ] Stage: Transaction setup [ INFO ] Stage: Misc configuration [ INFO ] Stage: Package installation [ INFO ] Stage: Misc configuration [ INFO ] Creating PostgreSQL 'engine' database [ INFO ] Configuring PostgreSQL [ INFO ] Stage: Transaction commit [ INFO ] Stage: Closing up [ INFO ] Stage: Clean up Log file is located at /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033923-c7vy1o.log [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination [ INFO ] Execution of provisiondb completed successfully 2019-01-02 03:39:28 13186: provisionDB: user ovirt_engine_history host localhost port 5432 database ovirt_engine_history secured False secured_host_validation False 2019-01-02 03:39:28 13186: OUTPUT: - user 'ovirt_engine_history', database 'ovirt_engine_history' [ INFO ] Stage: Initializing [ INFO ] Stage: Environment setup Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', '/etc/ovirt-engine-setup.conf.d/10-packaging.conf', '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf', '/tmp/engine-backup.bGOLRNXeD4/pg-provision-answer-file'] Log file: /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033928-nit1oc.log Version: otopi-1.7.8 (otopi-1.7.8-1.el7) [ INFO ] Stage: Environment packages setup [ INFO ] Stage: Programs detection [ INFO ] Stage: Environment customization [ INFO ] Stage: Setup validation [WARNING] Cannot validate host name settings, reason: resolved host does not match any of the local addresses [ INFO ] Stage: Transaction setup [ INFO ] Stage: Misc configuration [ INFO ] Stage: Package installation [ INFO ] Stage: Misc configuration [ INFO ] Creating PostgreSQL 'ovirt_engine_history' database [ INFO ] Configuring PostgreSQL [ INFO ] Stage: Transaction commit [ INFO ] Stage: Closing up [ INFO ] Stage: Clean up Log file is located at /var/log/ovirt-engine/setup/ovirt-engine-provisiondb-20190102033928-nit1oc.log [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination [ INFO ] Execution of provisiondb completed successfully 2019-01-02 03:39:34 13186: OUTPUT: Restoring: 2019-01-02 03:39:34 13186: Generating pgpass 2019-01-02 03:39:34 13186: Verifying connection 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U engine -h localhost -p 5432 engine -c select 1 ?column? -- 1 (1 row) 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U engine -h localhost -p 5432 engine -t -c show lc_messages 2019-01-02 03:39:34 13186: pg_cmd running: pg_dump -w -U engine -h localhost -p 5432 engine -s 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U ovirt_engine_history -h localhost -p 5432 ovirt_engine_history -c select 1 ?column? -- 1 (1 row) 2019-01-02 03:39:34 13186: pg_cmd running: psql -w -U ovirt_engine_history -h localhost -p 5432 ovirt_engine_history -t -c show lc_messages 2019-01-02 03:39:34 13186: pg_cmd running: pg_dump -w -U ovirt_engine_history -h localhost -p 5432 ovirt_engine_history -s 2019-01-02 03:39:34 13186: OUTPUT: - Engine