Bug 1021448

Summary: engine-backup.sh restore fails on non-inited db
Product: Red Hat Enterprise Virtualization Manager Reporter: Yedidyah Bar David <didi>
Component: ovirt-engine-setupAssignee: Yedidyah Bar David <didi>
Status: CLOSED DUPLICATE QA Contact: Pavel Stehlik <pstehlik>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.3.0CC: acathrow, bazulay, iheim, oschreib, Rhev-m-bugs, sbonazzo, yeylon
Target Milestone: ---Keywords: Triaged
Target Release: 3.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: integration
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-23 07:34:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Yedidyah Bar David 2013-10-21 10:22:01 UTC
Description of problem:

When running 'engine-backup.sh --mode=restore --file=file1', and the credentials kept in file1 do not work, it fails with "FATAL: Can't connect to the database".

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


How reproducible:

Always

Steps to Reproduce:
1. engine-setup
2. engine-backup.sh --mode=backup --file-file1
3. engine-cleanup
4. initdb
5. engine-backup.sh --mode=restore --file=file1

Actual results:

"FATAL: Can't connect to the database"

Expected results:

A message should be output helping the user setup a database with the credentials kept in the backup file.

Additional info:

In principle, engine-backup.sh could have done this by itself if the database was local, but this is non-trivial, already done by engine-setup, and will not be easy to replicate to this script without a complete rewrite (which might be done one day). It can't be done if the database is remote.

Comment 1 Yedidyah Bar David 2013-10-21 10:24:22 UTC
A solution was introduced during the review process for bug #1020277 (http://gerrit.ovirt.org/20264) but it was requested that it be separated out. Hence this bug.

Comment 2 Ofer Schreiber 2013-10-22 11:09:42 UTC
Well, https://bugzilla.redhat.com/1002401 is already covering this issue, isn't it?

Comment 3 Yedidyah Bar David 2013-10-22 12:33:12 UTC
(In reply to Ofer Schreiber from comment #2)
> Well, https://bugzilla.redhat.com/1002401 is already covering this issue,
> isn't it?

Yes. Eventually I just added stuff to usage().

Comment 4 Yedidyah Bar David 2013-10-23 07:34:46 UTC

*** This bug has been marked as a duplicate of bug 1002401 ***