[ovirt-users] Re-adding oVirt host.

2017-06-11 Thread Marcin M. Jessa

Hi guys.

I have a two node setup. One server running on CentOS [1] and one server 
with oVirt node [2].
I added local storage to my oVirt host but I forgot the storage I chose 
was already in use so it failed.
I then got a host entry with local storage which was shown as not 
configured.
I then removed that local storage host but then it completely 
disappeared from my setup.
Then I tried to add it again but oVirt said that host is already 
defined. I tried different name with the same IP but it also failed 
saying that that IP is already defined. Is there a way to re-add that 
previously defined host?

How can I bring it back?

[1]: oVirt Engine Version: 4.1.2.2-1.el7.centos
[2]: oVirt Node 4.1.2


Marcin Jessa.
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Fail to upgrade to 4.1 from 4.0

2016-09-15 Thread Marcin M. Jessa

Stuff finally works!

What I did was.
Removed everything ovirt-related:
# yum remove \*ovirt\* \*vdsm\* \*libvirt\*
# reboot

Installed 3.6 from scratch:
# yum install http://resources.ovirt.org/pub/yum-repo/ovirt-release36.rpm
# yum install ovirt-engine

Restored backup:
# su - postgres
# psql -d template1 -c "create database engine owner engine;
# engine-backup --mode=restore restore-permissions --provision-db 
--provision-dwh-db --provision-reports-db --file=engine-backup.tar.gz 
--log=engine-backup-restore.log


Now I'm back to working 3.6
Updating to 4.0
# yum install http://resources.ovirt.org/pub/yum-repo/ovirt-release40.rpm
# yum update "ovirt-engine-setup*"
# engine-setup

Cheers
Marcin.
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Fail to upgrade to 4.1 from 4.0

2016-09-15 Thread Marcin M. Jessa

On 15/09/2016 12:58, Martin Perina wrote:

​So something went wrong on that upgrade from 3.6 to 4.0 and  it was not
a good idea to do another upgrade when previous one went wrong.


The upgrade process went fine. The upgrade script never showed any errors.


Anyway to confirm that could you please share with us also upgrade log between
3.6 and 4.0? Also how did you do the upgrade (especially what OS have
you used on 3.6 and if upgrade was done using engine-backup or in-place)?


I backed up the installation but then I ran in-place upgrade. I was told 
on the irc I don't need to restore from backups when I'm already on 
CentOS 7. Actually failing to restore from backup brought me to the IRC 
in the first place.


I'm on CentOS Linux release 7.2.1511 (Core)
Upgrading I followed exactly the same doc you pointed to below.
Except when updating to 4.1 failed, I uninstalled everything that had to 
do with ovirt and installed the 4.0 release.



More details about upgrade options from 3.6 to 4.0 can be found at:
http://www.ovirt.org/documentation/migration-engine-3.6-to-4.0/

Because of that doc I installed 4.1 instead of the stable 4.0 ...


​So from current log I can see that upgrade from 3.6 to 4.0 was not
successfully finished and that's why you had issues during upgrade on
master.

Out of curiousity, where did you see that 3.6 to 4.0 update failed?


Personaly I'd recommend you to get back into 3.6 (either by restoring
from backup (if you performed in-place upgrade) or shutting down new
host and starte pervious 3.6 host (if you performed upgrade using
engine-backup) and do upgrade to 4.0 again​. And if upgrade from 3.6 to
4.0 is not successful, please share the logs again.


I'll try from scratch again, uninstalling everything, installing 3.6, 
restoring backups and upgrading to 4.0


I don't want to be a party popper but to be honest you need a testing 
engineer. The upgrade process is way too fragile and breaks too easily...


--

Marcin M. Jessa
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Fail to upgrade to 4.1 from 4.0

2016-09-15 Thread Marcin M. Jessa

Hi.

I never claimed it was a release ;)
Anyway. I followed your listed points adding the additional step but 
upgrade still fails exactly at the same point.


[ ERROR ] schema.sh: FATAL: Cannot execute sql command: 
--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql
[ ERROR ] Failed to execute stage 'Misc configuration': Engine schema 
refresh failed




Cheers,
Marcin.




On 15/09/2016 09:00, Martin Perina wrote:

Hi,

first of all there's no 4.1 release, it's master developement branch, so
things can be broken there :-)

Anyway if you really want to try latest master, please use correct
upgrade steps:

1. Do full backup of you 4.0 version

2. Add ovirt-master repositories
 ​yum install
http://resources.ovirt.org/pub/yum-repo/ovirt-release-master.rpm
<http://resources.ovirt.org/pub/yum-repo/ovirt-release-master.rpm>

3. Update engine-setup packages
yum update 'ovirt-engine-setup*'

4. Execute engine-setup


We have CI jobs testing regularly upgrade between 4.0 and master and
upgrade should be working OK unless we have a new bug here.
If above steps is not working for you please attach logs, especially
logs generated during engine-setup.

Thanks

Martin


On Wed, Sep 14, 2016 at 10:11 PM, Marcin M. Jessa <li...@yazzy.org
<mailto:li...@yazzy.org>> wrote:

Hi guys.

I have problems upgrading from oVirt 4.0 to 4.1
This is what I did:
#
​​
yum install
http://resources.ovirt.org/pub/yum-repo/ovirt-release-master.rpm
<http://resources.ovirt.org/pub/yum-repo/ovirt-release-master.rpm>
# yum -y update
# engine-setup

Then it fails with following error:
[ ERROR ] schema.sh: FATAL: Cannot execute sql command:

--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql
[ ERROR ] Failed to execute stage 'Misc configuration': Engine
schema refresh failed

This is the 04_01_0010_add_mac_pool_id_to_vds_group.sql script:

SELECT fn_db_add_column('cluster',
'mac_pool_id',
'UUID REFERENCES mac_pools (id)');

UPDATE
  cluster AS c
SET
  mac_pool_id = (
  SELECT
sp.mac_pool_id
  FROM
storage_pool sp
  WHERE
sp.id <http://sp.id> = c.storage_pool_id
);

ALTER TABLE cluster ALTER COLUMN mac_pool_id SET NOT NULL;


The relevant portion of the log file:
2016-09-14 21:56:19 DEBUG
otopi.plugins.ovirt_engine_setup.ovirt_engine.db.schema
plugin.execute:926 execute-output:
['/usr/share/ovirt-engine/dbscripts/schema.sh', '-s', 'localhost',
'-p', '5432', '-u', 'engine', '-d', 'engine', '-l',
'/var/log/ovirt-engine/setup/ovirt-engine-setup-20160914215252-64vhk6.log',

'-c', 'apply'] stderr:

psql:/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql:17:
ERROR:  column "mac_pool_id" contains null values
FATAL: Cannot execute sql command:

--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql

2016-09-14 21:56:19 ERROR
otopi.plugins.ovirt_engine_setup.ovirt_engine.db.schema
schema._misc:315 schema.sh: FATAL: Cannot execute sql command:

--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql
2016-09-14 21:56:19 DEBUG otopi.context context._executeMethod:142
method exception
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/otopi/context.py", line
132, in _executeMethod
method['method']()
  File

"/usr/share/ovirt-engine/setup/bin/../plugins/ovirt-engine-setup/ovirt-engine/db/schema.py",
line 317, in _misc
raise RuntimeError(_('Engine schema refresh failed'))
RuntimeError: Engine schema refresh failed
2016-09-14 21:56:19 ERROR otopi.context context._executeMethod:151
Failed to execute stage 'Misc configuration': Engine schema refresh
failed
2016-09-14 21:56:19 DEBUG otopi.transaction transaction.abort:119
aborting 'Yum Transaction'
2016-09-14 21:56:19 INFO otopi.plugins.otopi.packagers.yumpackager
yumpackager.info:80 <http://yumpackager.info:80> Yum Performing yum
transaction rollback


Any idea how to fix that?

--

Marcin M. Jessa
___
Users mailing list
Users@ovirt.org <mailto:Users@ovirt.org>
http://lists.ovirt.org/mailman/listinfo/users
<http://lists.ovirt.org/mailman/listinfo/users>





--

Marcin M. Jessa
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] Fail to upgrade to 4.1 from 4.0

2016-09-14 Thread Marcin M. Jessa

Hi guys.

I have problems upgrading from oVirt 4.0 to 4.1
This is what I did:
# yum install 
http://resources.ovirt.org/pub/yum-repo/ovirt-release-master.rpm

# yum -y update
# engine-setup

Then it fails with following error:
[ ERROR ] schema.sh: FATAL: Cannot execute sql command: 
--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql
[ ERROR ] Failed to execute stage 'Misc configuration': Engine schema 
refresh failed


This is the 04_01_0010_add_mac_pool_id_to_vds_group.sql script:

SELECT fn_db_add_column('cluster',
'mac_pool_id',
'UUID REFERENCES mac_pools (id)');

UPDATE
  cluster AS c
SET
  mac_pool_id = (
  SELECT
sp.mac_pool_id
  FROM
storage_pool sp
  WHERE
sp.id = c.storage_pool_id
);

ALTER TABLE cluster ALTER COLUMN mac_pool_id SET NOT NULL;


The relevant portion of the log file:
2016-09-14 21:56:19 DEBUG 
otopi.plugins.ovirt_engine_setup.ovirt_engine.db.schema 
plugin.execute:926 execute-output: 
['/usr/share/ovirt-engine/dbscripts/schema.sh', '-s', 'localhost', '-p', 
'5432', '-u', 'engine', '-d', 'engine', '-l', 
'/var/log/ovirt-engine/setup/ovirt-engine-setup-20160914215252-64vhk6.log', 


'-c', 'apply'] stderr:
psql:/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql:17: 
ERROR:  column "mac_pool_id" contains null values
FATAL: Cannot execute sql command: 
--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql


2016-09-14 21:56:19 ERROR 
otopi.plugins.ovirt_engine_setup.ovirt_engine.db.schema schema._misc:315 
schema.sh: FATAL: Cannot execute sql command: 
--file=/usr/share/ovirt-engine/dbscripts/upgrade/04_01_0010_add_mac_pool_id_to_vds_group.sql
2016-09-14 21:56:19 DEBUG otopi.context context._executeMethod:142 
method exception

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/otopi/context.py", line 132, 
in _executeMethod

method['method']()
  File 
"/usr/share/ovirt-engine/setup/bin/../plugins/ovirt-engine-setup/ovirt-engine/db/schema.py", 
line 317, in _misc

raise RuntimeError(_('Engine schema refresh failed'))
RuntimeError: Engine schema refresh failed
2016-09-14 21:56:19 ERROR otopi.context context._executeMethod:151 
Failed to execute stage 'Misc configuration': Engine schema refresh failed
2016-09-14 21:56:19 DEBUG otopi.transaction transaction.abort:119 
aborting 'Yum Transaction'
2016-09-14 21:56:19 INFO otopi.plugins.otopi.packagers.yumpackager 
yumpackager.info:80 Yum Performing yum transaction rollback



Any idea how to fix that?

--

Marcin M. Jessa
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users