RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1160930 - The guest agent service in rhel7 guest will be stopped after run the init command
Summary: The guest agent service in rhel7 guest will be stopped after run the init com...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-guest-agent
Version: 7.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Miroslav Rezanina
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On: 885406 1165176
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-11-06 02:28 UTC by zhenfeng wang
Modified: 2015-11-19 07:09 UTC (History)
16 users (show)

Fixed In Version: qemu-guest-agent-2.3.0-3.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-19 07:09:36 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2217 0 normal SHIPPED_LIVE qemu-guest-agent bug fix and enhancement update 2015-11-19 08:26:27 UTC

Description zhenfeng wang 2014-11-06 02:28:27 UTC
Description of problem:
The guest agent service in rhel7 guest will be stopped after run the init shell command
Version-Release number of selected component (if applicable):
host:
libvirt-1.2.8-6.el7.x86_64
qemu-kvm-rhev-2.1.2-6.el7.x86_64
kernel-3.10.0-196.el7.x86_64
systemd-208-15.el7.x86_64

guest
qemu-guest-agent-2.1.0-4.el7.x86_64

How reproducible:
100%

Steps to Reproduce:

1.Prepare a guest including the following content
#virsh dumpxml rhel7
--
  <pm>
    <suspend-to-mem enabled='yes'/>
    <suspend-to-disk enabled='yes'/>
  </pm>
--
<channel type='spicevmc'>
      <target type='virtio' name='com.redhat.spice.0'/>
      <alias name='channel1'/>
      <address type='virtio-serial' controller='0' bus='0' port='2'/>
    </channel>

 <channel type='unix'>
      <source mode='bind' path='/var/lib/libvirt/qemu/rhel7.agent'/>
      <target type='virtio' name='org.qemu.guest_agent.0'/>
      <alias name='channel2'/>
      <address type='virtio-serial' controller='0' bus='0' port='3'/>
    </channel>


2.Start the guest, then install the qemu-guest-agent service inside the guest
#virsh start rhel7
inside guest# yum install qemu-guest-agent
inside guest# systemctl start qemu-guest-agent
inside guest# systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; static)
   Active: active (running) since Thu 2014-10-30 07:56:48 EDT; 2min 59s ago
 Main PID: 586 (qemu-ga)
   CGroup: /system.slice/qemu-guest-agent.service
           └─586 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-p...

Oct 30 07:56:48 localhost.localdomain systemd[1]: Started QEMU Guest Agent

3.Run init 3 or init 5 command inside the guest, then, recheck the guest agent status
found the guest agent has been in inactive status
inside guest#init 3
inside guest#systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; static)
   Active: inactive (dead) since Thu 2014-10-30 08:01:20 EDT; 5s ago
  Process: 586 ExecStart=/usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_agent.0 --blacklist=${BLACKLIST_RPC} -F${FSFREEZE_HOOK_PATHNAME} (code=exited, status=0/SUCCESS)
 Main PID: 586 (code=exited, status=0/SUCCESS)
   CGroup: /system.slice/qemu-guest-agent.service

Oct 30 07:56:48 localhost.localdomain systemd[1]: Started QEMU Guest Agent.
Oct 30 08:01:19 localhost.localdomain systemd[1]: Stopping QEMU Guest Agent...
Oct 30 08:01:20 localhost.localdomain systemd[1]: Stopped QEMU Guest Agent.

                                          

Actual results:
The guest agent service was stopped after run init shell command

Expected results:
The service should keep in running status

Comment 2 Miroslav Rezanina 2014-11-18 13:52:46 UTC
Guest agent is not started on

Comment 3 Jeff Nelson 2014-12-16 21:52:52 UTC
Deferred to rhel-7.2 as this requires a fix in redhat-release.

Comment 9 Miroslav Rezanina 2015-08-25 14:26:25 UTC
Fix included in qemu-guest-agent-2.3.0-3.el7

Comment 11 Yanhui Ma 2015-08-27 09:43:30 UTC
reproduce the issue:

host:
qemu-kvm-rhev-2.3.0-17.el7.x86_64

guest:
qemu-guest-agent-2.3.0-2.el7

step:

1. boot a rhel7.2 guest with following cli:
/usr/libexec/qemu-kvm -S -M pc -cpu Opteron_G3 -enable-kvm -m 4096 \
-smp 4,sockets=4,cores=1,threads=1 -no-kvm-pit-reinjection -name sluo-test \
-uuid b18fdd6c-a213-4022-9ca4-5d07225e40b0 \
-rtc base=localtime,clock=host,driftfix=slew \
-device virtio-serial-pci,disable-legacy=true,disable-modern=false,id=virtio-serial0,max_ports=16,vectors=0,bus=pci.0,addr=0x3,ioeventfd=on \
-chardev spicevmc,id=charchannel0,name=vdagent \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0 -chardev socket,id=charchannel1,path=/home/testdisk/socketfile2Gqcow2,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=3,chardev=charchannel1,id=channel1,name=org.qemu.guest_agent.0 \
-drive file=/home/RHEL-Server-7.2-64-virtio-scsi.qcow2,if=none,id=drive-system-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop,serial=QEMU-DISK1 \
-device virtio-scsi-pci,id=scsi0,bus=pci.0,ioeventfd=off -device scsi-hd,bus=scsi0.0,drive=drive-system-disk,id=system-disk,channel=0,scsi-id=0,lun=0,ver=mike,serial=ababab,bootindex=1 \
-netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup \
-device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=08:2e:5f:0a:1d:b1,bus=pci.0,addr=0x5,bootindex=2 \
-qmp tcp:0:4444,server,nowait -k en-us -boot menu=on \
-vnc :1 -spice disable-ticketing,port=5931 -vga qxl -monitor stdio \

2.install the qemu-guest-agent service inside the guest
inside guest# yum install qemu-guest-agent
inside guest# systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; disabled)
   Active: active (running) since Thu 2015-08-27 17:27:27 CST; 10min ago
 Main PID: 3159 (qemu-ga)
   CGroup: /system.slice/qemu-guest-agent.service
           └─3159 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_ag...

Aug 27 17:27:27 dhcp-66-106-190.nay.redhat.com systemd[1]: Started QEMU Guest Agent.

3.Run init 3 or init 5 command inside the guest, then, recheck the guest agent status
found the guest agent has been in inactive status
inside guest#init 3
inside guest#systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; disabled)
   Active: inactive (dead) since Thu 2015-08-27 17:38:11 CST; 2s ago
  Process: 3159 ExecStart=/usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_agent.0 --blacklist=${BLACKLIST_RPC} -F${FSFREEZE_HOOK_PATHNAME} (code=exited, status=0/SUCCESS)
 Main PID: 3159 (code=exited, status=0/SUCCESS)

Aug 27 17:27:27 dhcp-66-106-190.nay.redhat.com systemd[1]: Started QEMU Guest Agent.
Aug 27 17:38:11 dhcp-66-106-190.nay.redhat.com systemd[1]: Stopping QEMU Guest Agent...
Aug 27 17:38:11 dhcp-66-106-190.nay.redhat.com systemd[1]: Stopped QEMU Guest Agent.

results:
The guest agent service was stopped after run init shell command

==============================================================================

verify the issue:
host:
qemu-kvm-rhev-2.3.0-17.el7.x86_64

guest:
qemu-guest-agent-2.3.0-3.el7

step:

1. boot a rhel7.2 guest with following cli:
/usr/libexec/qemu-kvm -S -M pc -cpu Opteron_G3 -enable-kvm -m 4096 \
-smp 4,sockets=4,cores=1,threads=1 -no-kvm-pit-reinjection -name sluo-test \
-uuid b18fdd6c-a213-4022-9ca4-5d07225e40b0 \
-rtc base=localtime,clock=host,driftfix=slew \
-device virtio-serial-pci,disable-legacy=true,disable-modern=false,id=virtio-serial0,max_ports=16,vectors=0,bus=pci.0,addr=0x3,ioeventfd=on \
-chardev spicevmc,id=charchannel0,name=vdagent \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0 -chardev socket,id=charchannel1,path=/home/testdisk/socketfile2Gqcow2,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=3,chardev=charchannel1,id=channel1,name=org.qemu.guest_agent.0 \
-drive file=/home/RHEL-Server-7.2-64-virtio-scsi.qcow2,if=none,id=drive-system-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop,serial=QEMU-DISK1 \
-device virtio-scsi-pci,id=scsi0,bus=pci.0,ioeventfd=off -device scsi-hd,bus=scsi0.0,drive=drive-system-disk,id=system-disk,channel=0,scsi-id=0,lun=0,ver=mike,serial=ababab,bootindex=1 \
-netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup \
-device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=08:2e:5f:0a:1d:b1,bus=pci.0,addr=0x5,bootindex=2 \
-qmp tcp:0:4444,server,nowait -k en-us -boot menu=on \
-vnc :1 -spice disable-ticketing,port=5931 -vga qxl -monitor stdio \

2.install the qemu-guest-agent service inside the guest
inside guest# yum install qemu-guest-agent
inside guest# systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; disabled)
   Active: active (running) since Thu 2015-08-27 17:27:27 CST; 10min ago
 Main PID: 3159 (qemu-ga)
   CGroup: /system.slice/qemu-guest-agent.service
           └─3159 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_ag...

Aug 27 17:27:27 dhcp-66-106-190.nay.redhat.com systemd[1]: Started QEMU Guest Agent.

3.Run init 3 or init 5 command inside the guest, then, recheck the guest agent status
inside guest#init 3
inside guest#systemctl status qemu-guest-agent
qemu-guest-agent.service - QEMU Guest Agent
   Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; disabled)
   Active: active (running) since Thu 2015-08-27 17:40:38 CST; 1s ago
 Main PID: 3997 (qemu-ga)
   CGroup: /system.slice/qemu-guest-agent.service
           └─3997 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_ag...

Aug 27 17:40:38 dhcp-66-106-190.nay.redhat.com systemd[1]: Starting QEMU Guest Agent...
Aug 27 17:40:38 dhcp-66-106-190.nay.redhat.com systemd[1]: Started QEMU Guest Agent.

results:
The service should keep in running status

Based on the above results, the bz has been fixed.

Comment 12 juzhang 2015-08-31 03:04:36 UTC
According to comment11, set this issue as verified.

Comment 14 errata-xmlrpc 2015-11-19 07:09:36 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://rhn.redhat.com/errata/RHBA-2015-2217.html


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