Bug 1699684

Summary: vm_init wiped on cluster level upgrade
Product: Red Hat Enterprise Virtualization Manager Reporter: Germano Veit Michel <gveitmic>
Component: ovirt-engineAssignee: Steven Rosenberg <srosenbe>
Status: CLOSED ERRATA QA Contact: Liran Rotenberg <lrotenbe>
Severity: high Docs Contact:
Priority: unspecified    
Version: 4.2.8CC: emarcus, mavital, michal.skrivanek, mtessun, rbarry, Rhev-m-bugs, srosenbe, vicente.balaguer
Target Milestone: ovirt-4.3.5Keywords: ZStream
Target Release: 4.3.5Flags: lrotenbe: testing_plan_complete+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: ovirt-engine-4.3.5 Doc Type: Bug Fix
Doc Text:
When updating an existing Cluster, all of the Virtual Machines residing on the cluster were also updated. However, when each Virtual Machine was initialized for updating, the initial run data was not loaded, and therefore appeared to be empty. In this release, there is an added initialization of the initial run data for each Virtual Machine before calling the VM Update functionality from the update cluster. This results in the initial run data being preserved and not deleted.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-12 11:53:27 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Virt RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Germano Veit Michel 2019-04-14 23:54:31 UTC
Description of problem:

Maybe not limited to, but this is the scenario the customer hit the problem and I reproduced it:
- Vms of a VM pool have vm_init wiped on cluster upgrade

Version-Release number of selected component (if applicable):
ovirt-engine-4.3.2.1-1.el7.noarch

How reproducible:
Always

Steps to Reproduce:
1. Create VM Pool, set OS to Windows, set Domain

engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid and vm_name = 'Win-1';
 vm_name |   domain    
---------+-------------
 Win-1   | test.domain
(1 row)

2. Upgrade cluster level from 4.2 to 4.3

3. Check sysprep configuration from the UI (its empty)

engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid;
 vm_name | domain 
---------+--------
(0 rows)

Actual results:
All sysprep configurations for the VM are gone

Expected results:
sysprep configuration persisted

Additional info:
Customer hit this from 4.1 to 4.2 CL upgrade, under 4.2.8 engine.

Comment 2 Germano Veit Michel 2019-04-16 00:16:09 UTC
Bumping severity, this is affecting upgrade to 4.2 for our customer.

Comment 3 RHV bug bot 2019-05-16 15:29:20 UTC
WARN: Bug status wasn't changed from MODIFIED to ON_QA due to the following reason:

[Found non-acked flags: '{'rhevm-4.3.z': '?'}', ]

For more info please contact: rhv-devops: Bug status wasn't changed from MODIFIED to ON_QA due to the following reason:

[Found non-acked flags: '{'rhevm-4.3.z': '?'}', ]

For more info please contact: rhv-devops

Comment 5 Liran Rotenberg 2019-06-03 06:42:50 UTC
Verification failed on:
ovirt-engine-4.3.4.1-0.1.el7.noarch

Steps:
1. Create a VM and a VM Pool, set OS to Windows, set Domain under initial init, sysprep.

engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid and vm_name = '<VM_NAME>';
 vm_name |   domain    
---------+-------------
 <VM_NAME>   | <DOMAIN>
(1 row)

2. Upgrade cluster level from 4.2 to 4.3

3. Check sysprep configuration from the UI (its empty)

engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid and vm_name = '<VM_NAME>';
 vm_name | domain 
---------+--------
(0 rows)

Additional information:
The patch merged only on master branch, in my opinion backport to 4.3 branch is needed.

Comment 8 Liran Rotenberg 2019-06-17 08:14:14 UTC
Verified on:
ovirt-engine-4.3.5-0.1.el7.noarch

Steps:
1. Create a VM and a VM Pool, set OS to Windows, set Domain under initial init, sysprep.

engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid and vm_name = '<VM_NAME>';
 vm_name |   domain    
---------+-------------
 <VM_NAME>   | <DOMAIN>
(1 row)

2. Upgrade cluster level from 4.2 to 4.3

3. Check sysprep configuration from the UI
The fields for initial run are full as before changing the cluster level.

4. Verify the engine's DB isn't change:
engine=# select vm_name,domain from vm_init,vms where vm_init.vm_id = vms.vm_guid and vm_name = '<VM_NAME>';
 vm_name |   domain    
---------+-------------
 <VM_NAME>   | <DOMAIN>
(1 row)

Comment 13 errata-xmlrpc 2019-08-12 11:53:27 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2019:2431