Bug 1703428 - VMs migrated from KVM to RHV show warning 'The latest guest agent needs to be installed and running on the guest'
Summary: VMs migrated from KVM to RHV show warning 'The latest guest agent needs to be...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 4.2.8
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ovirt-4.4.1
: ---
Assignee: Liran Rotenberg
QA Contact: Nisim Simsolo
URL:
Whiteboard:
Depends On:
Blocks: 1743427
TreeView+ depends on / blocked
 
Reported: 2019-04-26 11:55 UTC by Abhishekh Patil
Modified: 2020-08-04 13:19 UTC (History)
16 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Previously, when importing a KVM into Red Hat Virtualization, "Hardware Clock Time Offset" was not set. As a result, the Manager machine did not recognize the guest agent installed in the virtual machine. In this release, the Manager machine recognizes the guest agent on a virtual machine imported from KVM, and the "Hardware Clock Time Offset" won't be null.
Clone Of:
: 1743427 (view as bug list)
Environment:
Last Closed: 2020-08-04 13:19:21 UTC
oVirt Team: Virt
Target Upstream Version:
lsvaty: testing_plan_complete-


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 4116601 0 Troubleshoot None The latest guest agent needs to be installed and running on the guest 2019-05-08 00:40:32 UTC
Red Hat Product Errata RHSA-2020:3247 0 None None None 2020-08-04 13:19:56 UTC
oVirt gerrit 103348 0 'None' MERGED core: Add default timezone in import vm 2020-09-01 19:50:38 UTC

Description Abhishekh Patil 2019-04-26 11:55:12 UTC
Description of problem:

VMs migrated from KVM to RHV show the warning 'The latest guest agent needs to be installed and running on the guest'. 

The guest has ovirt-guest-agent-common and qemu-guest-agent installed:
~~~~~~~
ovirt-guest-agent-common-1.0.14-1.el7.noarch                
qemu-guest-agent-2.12.0-2.el7.x86_64                        
~~~~~~

Also, the services are running on the VM:
~~~~~~
* ovirt-guest-agent.service - oVirt Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/ovirt-guest-agent.service; enabled; vendor preset: disabled)
   Active: active (running) since Mon 2019-04-22 11:09:27 CDT; 20h ago
  Process: 2799 ExecStartPre=/bin/chown ovirtagent:ovirtagent /run/ovirt-guest-agent.pid (code=exited, status=0/SUCCESS)
  Process: 2766 ExecStartPre=/bin/touch /run/ovirt-guest-agent.pid (code=exited, status=0/SUCCESS)
  Process: 2749 ExecStartPre=/sbin/modprobe virtio_console (code=exited, status=0/SUCCESS)


* qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; enabled; vendor preset: enabled)
   Active: active (running) since Mon 2019-04-22 11:09:27 CDT; 20h ago
 Main PID: 2747 (qemu-ga)
   CGroup: /system.slice/qemu-guest-agent.service
           `-2747 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_agent.0 --blacklist=guest-file-open,guest-file-close,guest-file-read,guest-file-write,guest-file-seek,guest-file-flush,guest-exec,guest-exec-status -F/etc/qemu-ga/fsfreeze-hook
~~~~~~


Version-Release number of selected component (if applicable):
ovirt-guest-agent-common-1.0.14-1.el7.noarch                
qemu-guest-agent-2.12.0-2.el7.x86_64 

Actual results:

VMs show the warning 'The latest guest agent needs to be installed and running on the guest' on RHV portal. 

Expected results:
VMs should not show the warning  'The latest guest agent needs to be installed and running on the guest' on RHV portal if the guest-agent is installed on it.

Comment 2 Tomáš Golembiovský 2019-04-26 12:58:13 UTC
Please provide information from the 'Guest Agent info' tab for this VM.

Comment 3 bwalton 2019-04-26 19:22:40 UTC
Hi Tomáš.  Abhishekh opened this bug on my behalf.  So, I'll chime in.  By "Guest Agent info" tab for this VM, I assume you mean the "Guest Info" tab for the VM under Compute->Virtual Machines in the RHEV-M gui.  If so, here you go:

Type:
Linux

Timezone:
America/Chicago (UTC--06:-00)

Logged-in User:
None

Architecture:
x86_64

Console User:

Operating System:
Red Hat Enterprise Linux Server 7.6 (Maipo)

Console Client IP:

Kernel Version:
3.10.0-957.10.1.el7.x86_64

Comment 5 Michal Skrivanek 2019-04-29 10:11:48 UTC
what's the OS Type set for that VM?

Comment 7 bwalton 2019-04-29 12:57:20 UTC
When I imported the VM from our KVM installation, I chose "Red Hat Enterprise Linux 7.x x64" in the Operating System field.  If there is some other place you would like me to look for this setting, please let me know.

Comment 8 bwalton 2019-04-29 13:01:33 UTC
Also, output from:

[root@rhevm bwalton]# /usr/share/ovirt-engine/dbscripts/engine-psql.sh -c "select vm_name,guestos_type from vms where vm_name='migratetest';"
   vm_name   | guestos_type 
-------------+--------------
 migratetest | Linux
(1 row)

[root@rhevm bwalton]#

Comment 9 Tomáš Golembiovský 2019-04-29 13:20:48 UTC
I think it checks OS version reported by guest agent, not from VM options. And based on comment #3 it looks OK to me.
In logs I see the ovirt-engine version is 4.2.8.3-0.1.el7ev

Shmuel, any ideas?

Comment 10 Michal Skrivanek 2019-04-30 10:54:05 UTC
I'm puzzled by that as well, the "guestAgentNotAvailable" message is only displayed when the guest agent is not detected (VM is Up and hasGuestAgent(vm) returns false) which has this condition:
vm.getTimeZone() != null && vm.getGuestOsType() != null && vm.getGuestOsType() != OsType.Other;

clearly TZ is reported and OS is not Other.

Can you doublecheck/paste the whole row in "vms" table for this VM please? You can add that as a private comment.

Comment 11 Michal Skrivanek 2019-04-30 10:56:09 UTC
Still it looks like a frontend issue only, the agent is apparently running and reporting all the info so from that perspective all the functionality should be ok

Comment 12 Tomáš Golembiovský 2019-04-30 11:21:37 UTC
It may that there is some internal inconsistency about the timezone info
- the zone info in Guest Info tab comes from vm.getGuestOsTimezoneName()
- but the check is performed against vm.getTimeZone() (which despite the name is also from guest info)

Just for the record, you could you please run: 

    vdsm-client Host getAllVmStats

What is the content of `guestTimezone` structure?

Comment 13 bwalton 2019-04-30 12:30:00 UTC
Tomáš, 

when I run "vdsm-client Host getAllVmStats" on the hypervisor, the output for guestTimezone shows:

        "guestTimezone": {
            "zone": "America/Chicago", 
            "offset": -360
        }, 


Michal,

I apologize, but would you please tell me how/where to find the "vms" table for the VM?

Thanks!

Comment 16 Marina Kalinin 2019-05-06 17:28:39 UTC
Tomas, Shmuel:
Same value is in the database for this vm:
guest_timezone_offset          | -360
guest_timezone_name            | America/Chicago

Can you please check next steps?

Comment 27 Daniel Gur 2019-08-28 13:13:31 UTC
sync2jira

Comment 28 Daniel Gur 2019-08-28 13:17:45 UTC
sync2jira

Comment 29 RHV bug bot 2019-12-13 13:13:14 UTC
WARN: Bug status (ON_QA) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.comINFO: Bug status (ON_QA) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.com

Comment 30 Nisim Simsolo 2019-12-15 14:24:13 UTC
Verified:
rhvm-4.4.0-0.9.master.el7
vdsm-4.40.0-164.git38a19bb.el8ev.x86_64
qemu-kvm-4.1.0-10.module+el8.1.0+4234+33aa4f57.x86_64
libvirt-5.6.0-5.module+el8.1.0+4229+2e4e348c.x86_64

Verification scenario: 
1. Prepare the next VMs on KVM server:
- RHEL 7 VM without ovirt and qemu guest agents and EDT hwclock
- RHEL 7 VM with ovirt and qemu guest agents and EDT hwclock
(ovirt host hwclock is IST, so it's an offset of -6 hours)
2. From RHV WebAdmin, import both VMs and run them.
3. On the VM with guest agent, verify services are up and guest agent is in sync with the host.
4. Observe VMs warning messages on WebAdmin -> virtual machines view:
- No message should be observed on the VM with guest agents.
- 'The latest guest agent needs to be installed and running on the guest' warning message should be on the VM without guest agents.

Comment 31 RHV bug bot 2019-12-20 17:43:17 UTC
WARN: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.comINFO: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.com

Comment 32 RHV bug bot 2020-01-08 14:46:27 UTC
WARN: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.comINFO: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.com

Comment 33 RHV bug bot 2020-01-08 15:13:49 UTC
WARN: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.comINFO: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.com

Comment 34 RHV bug bot 2020-01-24 19:48:12 UTC
WARN: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.comINFO: Bug status (VERIFIED) wasn't changed but the folowing should be fixed:

[Found non-acked flags: '{}', ]

For more info please contact: rhv-devops@redhat.com

Comment 41 errata-xmlrpc 2020-08-04 13:19:21 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 (Important: RHV Manager (ovirt-engine) 4.4 security, bug fix, and enhancement update), 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/RHSA-2020:3247


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