Bug 884444 - engine-setup fails in db creation for all in one configuration
Summary: engine-setup fails in db creation for all in one configuration
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: ovirt-engine
Version: 18
Hardware: Unspecified
OS: Unspecified
urgent
unspecified
Target Milestone: ---
Assignee: Juan Hernández
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-06 09:25 UTC by Gianluca Cecchi
Modified: 2013-02-08 21:09 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-01-11 23:24:15 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
log file produced by engine-setup (66.88 KB, text/x-log)
2012-12-06 09:25 UTC, Gianluca Cecchi
no flags Details
log from db_install .sh (1.92 KB, text/x-log)
2012-12-06 09:35 UTC, Gianluca Cecchi
no flags Details
egine log (38.53 KB, text/x-log)
2012-12-07 16:00 UTC, Gianluca Cecchi
no flags Details
server.log (50.65 KB, text/x-log)
2012-12-07 16:01 UTC, Gianluca Cecchi
no flags Details
boot.log (5.13 KB, text/x-log)
2012-12-07 16:01 UTC, Gianluca Cecchi
no flags Details

Description Gianluca Cecchi 2012-12-06 09:25:38 UTC
Created attachment 658592 [details]
log file produced by engine-setup

Description of problem:
create database error when configuring all-in-one in Fedora 18

Version-Release number of selected component (if applicable):
ovirt-engine-setup-3.1.0-1.fc18.noarch

How reproducible:
always

Steps to Reproduce:
1. install Fedora final beta from netinst.iso
2. yum install ovirt-engine-setup-plugin-allinone
3. run engine-setup
  
Actual results:
Creating Database...                                            [ ERROR ]
Database creation failed

Expected results:
completion of initial setup

Additional info:
I accepted default values:

oVirt Engine will be installed using the following configuration:
=================================================================
http-port:                     80
https-port:                    443
host-fqdn:                     f18ov31.localdomain.local
auth-pass:                     ********
org-name:                      Tekka oVirt
default-dc-type:               NFS
db-remote-install:             local
db-local-pass:                 ********
nfs-mp:                        /ISO
iso-domain-name:               ISO
override-iptables:             yes
config-allinone:               yes
storage-path:                  /DATA
superuser-pass:                ********
Proceed with the configuration listed above? (yes|no): yes

Installing:
AIO: Validating CPU Compatibility...                               [ DONE ]
Configuring oVirt-engine...                                        [ DONE ]
Creating CA...                                                     [ DONE ]
Editing JBoss Configuration...                                     [ DONE ]
Setting Database Configuration...                                  [ DONE ]
Setting Database Security...                                       [ DONE ]
Creating Database...                                            [ ERROR ]
Database creation failed
Please check log file /var/log/ovirt-engine/engine-setup_2012_12_06_10_16_54.log for more information
Exception in thread libvirtEventLoop (most likely raised during interpreter shutdown):
Traceback (most recent call last):
  File "/usr/lib64/python2.7/threading.py", line 551, in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 504, in run
  File "/usr/share/vdsm/libvirtev.py", line 406, in virEventLoopPureRun
  File "/usr/share/vdsm/libvirtev.py", line 233, in run_loop
  File "/usr/share/vdsm/libvirtev.py", line 212, in run_once
<type 'exceptions.AttributeError'>: 'NoneType' object has no attribute 'time'

I'm going to attach /var/log/ovirt-engine/engine-setup_2012_12_06_10_16_54.log

Comment 1 Gianluca Cecchi 2012-12-06 09:35:03 UTC
Created attachment 658597 [details]
log from db_install .sh

Comment 2 Juan Hernández 2012-12-06 15:09:17 UTC
The reason for this problem is that the database creation script checks the version number of the PostgreSQL database in order to create the UUID extension correctly, is the way to create it is different in PostgreSQL 8 and PostgreSQL 9. But we check for version 9.1, and Fedora 18 includes 9.2, as a result we end up trying to use the PostgreSQL 8 mechanism, and it fails.

I am preparing a patch to fix that in the official fedora package.

This is not really relevant upstream 3.2 as we don't use the UUID extension any more.

I am also moving the bug to the ovirt-engine Fedora component.

Comment 3 Fedora Update System 2012-12-06 22:15:33 UTC
ovirt-engine-3.1.0-2.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/ovirt-engine-3.1.0-2.fc18

Comment 4 Gianluca Cecchi 2012-12-07 15:46:05 UTC
The test fix seems to work for the DB creation problem.
Now infact I get:

Installing:
AIO: Validating CPU Compatibility...                               [ DONE ]
Configuring oVirt-engine...                                        [ DONE ]
Creating CA...                                                     [ DONE ]
Editing JBoss Configuration...                                     [ DONE ]
Setting Database Configuration...                                  [ DONE ]
Setting Database Security...                                       [ DONE ]
Creating Database...                                               [ DONE ]
Updating the Default Data Center Storage Type...                   [ DONE ]
Editing oVirt Engine Configuration...                              [ DONE ]
Editing Postgresql Configuration...                                [ DONE ]
Configuring the Default ISO Domain...                              [ DONE ]
Configuring Firewall (iptables)...                                 [ DONE ]
Starting JBoss Service...                                          [ DONE ]
Handling HTTPD...                                                  [ DONE ]
AIO: Creating storage directory...                                 [ DONE ]
AIO: Adding Local Datacenter and cluster...                        [ DONE ]

But at the last part then

AIO: Adding Local host (This may take several minutes)...       [ ERROR ]
Error: Timed out while waiting for host to start
Please check log file /var/log/ovirt-engine/engine-setup_2012_12_07_16_33_30.log for more information
Exception in thread libvirtEventLoop (most likely raised during interpreter shutdown):
Traceback (most recent call last):
  File "/usr/lib64/python2.7/threading.py", line 551, in __bootstrap_inner
  File "/usr/lib64/python2.7/threading.py", line 504, in run
  File "/usr/share/vdsm/libvirtev.py", line 406, in virEventLoopPureRun
  File "/usr/share/vdsm/libvirtev.py", line 233, in run_loop
  File "/usr/share/vdsm/libvirtev.py", line 212, in run_once
<type 'exceptions.AttributeError'>: 'NoneType' object has no attribute 'time'

Let me know if I have to create a different bugzilla for this.
Note that I'm testing in a F18 vm inside a F17 host.


In log file
2012-12-07 16:35:36::DEBUG::all_in_one_100::399::root:: Checking JBoss status.
2012-12-07 16:35:36::INFO::all_in_one_100::402::root:: JBoss is up and running.
2012-12-07 16:35:36::DEBUG::setup_sequences::59::root:: running initAPI
2012-12-07 16:35:36::DEBUG::all_in_one_100::197::root:: Initiating the API object
2012-12-07 16:35:39::DEBUG::setup_sequences::59::root:: running createDC
2012-12-07 16:35:39::DEBUG::all_in_one_100::213::root:: Creating the local datacenter
2012-12-07 16:35:39::DEBUG::setup_sequences::59::root:: running createCluster
2012-12-07 16:35:39::DEBUG::all_in_one_100::224::root:: Creating the local cluster
2012-12-07 16:35:40::DEBUG::setup_sequences::59::root:: running createHost
2012-12-07 16:35:40::DEBUG::all_in_one_100::237::root:: Adding the local host
2012-12-07 16:35:42::DEBUG::setup_sequences::59::root:: running waitForHostUp
2012-12-07 16:35:42::DEBUG::all_in_one_100::252::root:: Waiting for host to become operational
2012-12-07 16:35:43::DEBUG::all_in_one_100::255::root:: current host status is: installing
2012-12-07 16:35:43::DEBUG::all_in_one_100::266::root:: Traceback (most recent call last):
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line 263, in isHostUp
    raise Exception(INFO_CREATE_HOST_WAITING_UP)
Exception: Waiting for the host to start

2012-12-07 16:35:48::DEBUG::all_in_one_100::252::root:: Waiting for host to become operational
2012-12-07 16:35:48::DEBUG::all_in_one_100::255::root:: current host status is: installing
2012-12-07 16:35:48::DEBUG::all_in_one_100::266::root:: Traceback (most recent call last):
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line 263, in isHostUp
    raise Exception(INFO_CREATE_HOST_WAITING_UP)
Exception: Waiting for the host to start

2012-12-07 16:35:53::DEBUG::all_in_one_100::252::root:: Waiting for host to become operational
2012-12-07 16:35:53::DEBUG::all_in_one_100::255::root:: current host status is: installing
2012-12-07 16:35:53::DEBUG::all_in_one_100::266::root:: Traceback (most recent call last):
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line 263, in isHostUp
    raise Exception(INFO_CREATE_HOST_WAITING_UP)
Exception: Waiting for the host to start

2012-12-07 16:35:58::DEBUG::all_in_one_100::252::root:: Waiting for host to become operational
2012-12-07 16:35:58::DEBUG::all_in_one_100::255::root:: current host status is: installing
2012-12-07 16:35:58::DEBUG::all_in_one_100::266::root:: Traceback (most recent call last):
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line 263, in isHostUp
    raise Exception(INFO_CREATE_HOST_WAITING_UP)
Exception: Waiting for the host to start

2012-12-07 16:36:03::DEBUG::all_in_one_100::252::root:: Waiting for host to become operational
2012-12-07 16:36:03::DEBUG::all_in_one_100::255::root:: current host status is: installing
2012-12-07 16:36:03::DEBUG::all_in_one_100::266::root:: Traceback (most recent call last):
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line 263, in isHostUp
    raise Exception(INFO_CREATE_HOST_WAITING_UP)
Exception: Waiting for the host to start

From a db point of view it seems ok.
postgres=# \c engine
You are now connected to database "engine" as user "postgres".
engine=# \d
                             List of relations
 Schema |                     Name                      |   Type   | Owner  
--------+-----------------------------------------------+----------+--------
 public | action_version_map                            | table    | engine
 public | ad_groups                                     | table    | engine
 public | all_disks                                     | view     | engine
 public | async_tasks                                   | table    | engine
 public | audit_log                                     | table    | engine
 public | audit_log_seq                                 | sequence | engine
 public | base_disks                                    | table    | engine
 public | bookmarks                                     | table    | engine
 public | business_entity_snapshot                      | table    | engine
 public | custom_actions                                | table    | engine
 public | custom_actions_seq                            | sequence | engine
 public | desktop_vms                                   | view     | engine
..

Comment 5 Gianluca Cecchi 2012-12-07 15:50:34 UTC
ALso, going at

http://f18ov31

I don't get the webadmin portal but a page with:
Welcome to Open Virtualization Manager.
Version 3.1.0-2
Note: You are using a stripped down version, full version with GUI included can be downloaded in oVirt Project Site

I thought to get the webadmin portal...

Comment 6 Gianluca Cecchi 2012-12-07 16:00:40 UTC
Created attachment 659487 [details]
egine log

Comment 7 Gianluca Cecchi 2012-12-07 16:01:15 UTC
Created attachment 659488 [details]
server.log

Comment 8 Gianluca Cecchi 2012-12-07 16:01:58 UTC
Created attachment 659489 [details]
boot.log

Comment 9 Fedora Update System 2012-12-07 20:45:35 UTC
Package ovirt-engine-3.1.0-2.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing ovirt-engine-3.1.0-2.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-19952/ovirt-engine-3.1.0-2.fc18
then log in and leave karma (feedback).

Comment 10 Juan Hernández 2012-12-08 12:53:36 UTC
Gianluca, the GUI is not packaged for Fedora because it is based in GWT and GWT itself is not yet package for Fedora, this is expected and we can't fix it short term.

Regarding the timeout when installing the host I would appreciate if you can check the bootstrap logfiles in the /tmp directory. The most probable reason is that the installation/update of packages takes very long.

Comment 11 Gianluca Cecchi 2012-12-08 18:02:49 UTC
OK. 
But on another system I'm also testing f18, but  with nightly build for oVirt at
http://ovirt.org/releases/nightly/rpm/Fedora/18/noarch/
and there, when I install and run engine-setup in all-in-one mode I then get the whole webadmin portal...

Also, based on this artcile for f17:
http://blog.jebpages.com/archives/up-and-running-with-ovirt-3-1-edition/

I presumed the same to be already in place for f18 in all-in-one configuration...
Now I'm sort of baffled..

Comment 12 Itamar Heim 2012-12-08 21:11:35 UTC
Gianuluca,

there is a difference between the ovirt repo which contains rpm's for fedora, and the rpm's that come out of the box with fedora.
those in fedora don't include the gwt based admin/portal yet.

hope this is clearer.

Thanks,
   Itamar

Comment 13 Gianluca Cecchi 2012-12-09 14:53:59 UTC
Ok, now it is clear and I also read that for F18 we are at first line of contingency plan (no GUI).
But at ths point what actually can be done without the GUI itself..?
Any pointer to alternative tools to use oVirt for if you don't have any gui?

Gianluca

Comment 14 Gianluca Cecchi 2012-12-09 20:04:46 UTC
BTW: no bootstrap file in my /tmp directory. I don't know if they are deleted at the end or after reboot.

[g.cecchi@f18ov31 ~]$ sudo ls -a /tmp
.	    hsperfdata_ovirt  .s.PGSQL.5432.lock      systemd-private-TONsV1  .XIM-unix
..	    .ICE-unix	      systemd-private-owmpqu  .Test-unix
.font-unix  .s.PGSQL.5432     systemd-private-P4SqgO  .X11-unix

How can I reinstall my all-in-one host without the gui, so that I eventually check bootstrap files again?

Comment 15 Itamar Heim 2012-12-10 07:25:09 UTC
juan, can we create supporting ui rpm's for the fedora version until the gwt makes it?
Gianluca - you can simply install everything from ovirt repo for now

Comment 16 Gianluca Cecchi 2012-12-10 15:56:16 UTC
Ok Itamar thanks. I'll go with ovirt stable repo for f18.
And to be sure, then in case of problems where should I post, here or in any ovirt bugzilla page?

Comment 17 Gianluca Cecchi 2012-12-10 23:17:12 UTC
In ovirt-stable repo for F18 the same bug for create DB is still present (ovirt-engine-setup-3.1.0-4.fc17.noarch).
Is there a similar patch as in comment 3 of this bug for the ovirt stable repo for f18?
Or do I have to post a new bugzilla for Product=oVirt ?

Comment 18 Juan Hernández 2012-12-11 08:51:33 UTC
Gianluca, the package that you mention is the 3.1.0 upstream version for Fedora 17, not for Fedora 18. The changes that fix the database creation issue didn't go into upstream 3.1.0, only in 3.2.0 (yet to be released). I made a patch for 3.1.0 and Fedora 18 but only for the "official" Fedora package, not for upstream. If we want this fixed upstream for 3.1.0 and Fedora 18 then we would need to backport several patches that we did for 3.2.0 and Fedora 18, and then we would need to do a new upstream 3.1.z release. Taking into account that the focus of developers right now is closing the 3.2.0 release I think this will never happen.

I would rather focus on testing 3.2.0 upstream in Fedora 18.

If you still think that this needs to be fixed in upstream 3.1.0 then please file a bug for the oVirt product, maybe clone this one.

Comment 19 Gianluca Cecchi 2012-12-11 09:09:13 UTC
I keep understanding less and less the more I use it ;-)
So what would be the advisable repo to use for F18 that is more useful both for the final users and the developers?
Based on other comments I went and tried this
http://resources.ovirt.org/releases/stable/rpm/Fedora/18/noarch/
that indeed contains packages marked as fc17....
And indeed it contains 3.1 based rpms...
Instead what is the preferred repo/set of packages to invest on f18? 
nightly build? 
beta (I'd say no, because this still contains 3.1 packages)?
other?

Anyway I also put a bugzilla for oVirt:
https://bugzilla.redhat.com/show_bug.cgi?id=885900

I'm going to start a Lab for a public municipality for desktop/server virtualization, beginning with virtual desktops for the book library and I would like to get both a "stable" environment and one that can give precisely an invision about future features...
Thanks,
Gianluca

Comment 20 Fedora Update System 2013-01-11 23:24:18 UTC
ovirt-engine-3.1.0-2.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 21 Gianluca Cecchi 2013-02-08 21:09:36 UTC
my environment was at first migrated to 3.2 nightly (before beta) and then to 3.2 beta.
So I have not it at the moment... but if other ones said is good, is good for me too...

Gianluca


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