Bug 1573880 - Restoring Backup on Selfhosted-Engine fails due to connected storage domain
Summary: Restoring Backup on Selfhosted-Engine fails due to connected storage domain
Alias: None
Product: ovirt-hosted-engine-setup
Classification: oVirt
Component: General
Version: 2.2.16
Hardware: x86_64
OS: Linux
Target Milestone: ---
: ---
Assignee: Ido Rosenzwig
QA Contact: meital avital
Depends On:
TreeView+ depends on / blocked
Reported: 2018-05-02 12:33 UTC by Matthias
Modified: 2018-06-05 13:55 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2018-06-05 13:55:47 UTC
oVirt Team: Docs

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1420604 0 urgent CLOSED [Docs][SHE] Review, test, and update the procedure for restoring a self-hosted engine environment 2021-03-11 17:12:43 UTC

Internal Links: 1420604

Description Matthias 2018-05-02 12:33:37 UTC
Description of problem:
Hello Red-Hat Team,

I wanted to try out the use-case for restoring a selfhosted engine environment. I used the documentation from https://www.ovirt.org/documentation/self-hosted/chap-Backing_up_and_Restoring_an_EL-Based_Self-Hosted_Environment/

1. I set my target host into maintenance mode
2. took backup
3. removed the host from the environment
4. shutdown the old environment
5. reinstalled CentOS 7-minimal on the target host, so complete clean setup
6. yum install http://resources.ovirt.org/pub/yum-repo/ovirt-release42.rpm
7. yum install ovirt-hosted-engine-setup
8. yum install ovirt-engine-appliance
9. yum install hosted-engine --deploy --noansible

But the installation fails due to following error: 

[ ERROR ] Failed to execute stage 'Environment customization': This host is already connected to a storage domain named hosted_storage, please deploy on a clean system.
[ INFO  ] Stage: Clean up
[ INFO  ] Generating answer file '/var/lib/ovirt-hosted-engine-setup/answers/answers-20180502142337.conf'
[ INFO  ] Stage: Pre-termination
[ INFO  ] Stage: Termination
[ ERROR ] Hosted Engine deployment failed


I tried hosted-engine --disconnect-storage, but the engine is not deployed, obviously, since I used a clean system.

Can you tell me, if my procedure of ovirt-self-hosted backup restore is wrong?

Thanks a lot,

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. take backup with host in target host in maintenance
2. start deployment with --noansible option on clean install

Actual results:
Error as seen above

Expected results:
Script should continue with the setup

Comment 1 Ido Rosenzwig 2018-06-05 07:20:38 UTC
Did you cleaned the storage domain before running the hosted-engine deployment ?

Comment 2 Matthias 2018-06-05 07:23:27 UTC
(In reply to Ido Rosenzwig from comment #1)
> Did you cleaned the storage domain before running the hosted-engine
> deployment ?

Hello Ido,

I did not clean my storage domain, since I wanted to keep my VMs. Or am I wrong about my workflow?


Comment 3 Ido Rosenzwig 2018-06-05 13:34:10 UTC
It is recommended to separate the Hosted-Engine storage domain from the other storage domains, so only the hosted-engine VM will be on the Hosted-Engine storage domain, this way it can easily be destroyed.

Please use another clean SD for the deployment.
After you restore the backup add the SD with all the VMs on the engine's web UI and import VMs to the new env.

Comment 4 Matthias 2018-06-05 13:38:38 UTC
So you mean the hostend_storage domain of the engine. This should be cleaned before redeploying the backup?

Comment 5 Ido Rosenzwig 2018-06-05 13:47:55 UTC
yes. when you are requested to provide a storage domain on hosted-engine --deploy --noansible , the storage domain need to be empty.

Comment 6 Matthias 2018-06-05 13:49:29 UTC
oke thank you very much and i will try it out. I think this thread can be closed now.

Comment 7 Ido Rosenzwig 2018-06-05 13:55:47 UTC
OK, if you still having trouble you can open a new bug or send an email to users@ovirt.org

Note You need to log in before you can comment on or make changes to this bug.