Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1888142 - Confusing warning message in the logs while shutting down a pool VM
Summary: Confusing warning message in the logs while shutting down a pool VM
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 4.4.2
Hardware: All
OS: Linux
unspecified
low
Target Milestone: ovirt-4.4.4
: 4.4.4
Assignee: Arik
QA Contact: Tamir
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-10-14 07:53 UTC by nijin ashok
Modified: 2021-02-11 02:30 UTC (History)
3 users (show)

Fixed In Version: ovirt-engine-4.4.4.4
Doc Type: Bug Fix
Doc Text:
Previously, stateless virtual machines including pool virtual machines issued a warning regarding not using the latest version, even when the virtual machine was not set to use the last version. In this release, there is no attempt to change the version of the template that virtual machines are based on unless they are set to use the last version of a template and thus this warning is omitted from the log.
Clone Of:
Environment:
Last Closed: 2021-02-02 13:58:29 UTC
oVirt Team: Virt
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 5790641 0 None None None 2021-02-11 02:30:20 UTC
Red Hat Product Errata RHBA-2021:0312 0 None None None 2021-02-02 13:58:44 UTC
oVirt gerrit 111985 0 master MERGED core: Warn when not restoring stateless 2021-02-10 06:31:56 UTC

Description nijin ashok 2020-10-14 07:53:42 UTC
Description of problem:

If a pool is set to a specific version of a template, below message is logged in engine log everytime a pool VM is powered down with log level WARN.

2020-10-14 13:22:22,600+05 WARN  [org.ovirt.engine.core.bll.UpdateVmVersionCommand] (EE-ManagedThreadFactory-engine-Thread-48) [74f4161b] Validation of action 'UpdateVmVersion' failed for user SYSTEM. Reasons: VAR__ACTION__UPDATE_VM_VERSION,VAR__TYPE__VM,ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST

This confuses the user and incorrectly assumes that there is some issue with the VM pools.

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

rhvm-4.4.2.6-0.2.el8ev.noarch

How reproducible:

100%

Steps to Reproduce:

1. Create a pool and set it to specific version instead of latest.
2. Start the pool VM and then stop it.
3. Watch for the message "ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST" in the engine logs while engine restores the stateless snapshot.

Actual results:

Confusing warning message in the logs while shutting down a pool VM

Expected results:

I think this should be an info message telling that VM is set to specific template version instead of a warning message.

Additional info:

Comment 1 Steven Rosenberg 2020-10-27 11:43:52 UTC
I reviewed this issue. It looks like the printing of the message is in a generic place that will affect other messages as well [1].

We would need to consider other messages that would be affected. It might just be that the term "failed for user" could be modified, but more investigation would be needed to see what other messages are affected. For now at least maybe we can agree to keep it as a warning and just consider a small change to the referenced term.

[1] https://github.com/oVirt/ovirt-engine/blob/master/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java#L830

Comment 2 Arik 2020-10-27 14:39:04 UTC
Steven, please look at the failed validation:
https://github.com/oVirt/ovirt-engine/blob/master/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/UpdateVmVersionCommand.java#L119-L121
We really should not produce this error when the VM is not set to use the latest version every time it does down..

Comment 6 Tamir 2020-12-13 15:26:16 UTC
Verified on RHV 4.4.4-5. All looks good to me.

Env:
  - Engine instance with RHV 4.4.4-5 (ovirt-engine-4.4.4.4-0.9.el8ev) and RHEL 8.3 installed.
  - 2 hosts with RHV 4.4.4-5 and RHEL 8.3, 3 hosts with vdsm-4.40.40-1.el8ev

Steps:

In Admin Portal:

1. Create a 4.5 data center and a 4.5 cluster.
2. Install the host and create a new NFS storage domain.
3. Create a pool with a template with base version 1 and wait for the VM's creation.
4. Start the VM.
5. Stop the VM.
6. Check the engine.log for any WARN message or the "ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST" message.
7. Edit the pool to the latest template version.
8. Start the VM.
9. Stop the VM.
10. Check the engine.log for any WARN message or the "ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST" message.


Results (As Expected):
1. The 4.5 data center and the 4.5 cluster were created.
2. The host was installed and the NFS storage domain was created.
3. The pool with a template with base version 1 was created.
4. The VM is running.
5. The VM is down.
6. There aren't any WARN or "ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST" messages.
7. The pool was changed to the latest template version.
8. The VM is running.
9. The VM is down.
10. There aren't any WARN or "ACTION_TYPE_FAILED_VM_NOT_SET_FOR_LATEST" messages.

Comment 9 Arik 2021-01-31 15:44:54 UTC
The previous text wasn't accurate - it's not that there is no data to check if the VM is using the last version.
Eli, how about the following to better reflect the fix:
Previously, stateless virtual machines including pool virtual machines issued a warning regarding not using the latest version, even when the virtual machine was not set to use the last version.
In this release, there is no attempt to change the version of the template that virtual machines are based on unless they are set to use the last version of a template and thus this warning is omitted from the log.

Comment 10 Eli Marcus 2021-01-31 20:37:39 UTC
(In reply to Arik from comment #9)
> The previous text wasn't accurate - it's not that there is no data to check
> if the VM is using the last version.
> Eli, how about the following to better reflect the fix:
> Previously, stateless virtual machines including pool virtual machines
> issued a warning regarding not using the latest version, even when the
> virtual machine was not set to use the last version.
> In this release, there is no attempt to change the version of the template
> that virtual machines are based on unless they are set to use the last
> version of a template and thus this warning is omitted from the log.

thank you, updated here and in the advisory

Comment 13 errata-xmlrpc 2021-02-02 13:58:29 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 (RHV Engine and Host Common Packages 4.4.z [ovirt-4.4.4]), 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/RHBA-2021:0312


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