Bug 1036561 - Virt-who start failed when set it to non-background mode
Summary: Virt-who start failed when set it to non-background mode
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-who
Version: 7.0
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Radek Novacek
QA Contact: gaoshang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-02 09:51 UTC by Liushihui
Modified: 2016-12-01 00:32 UTC (History)
4 users (show)

Fixed In Version: virt-who-0.8-10.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-13 10:39:22 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Liushihui 2013-12-02 09:51:30 UTC
Description of problem:
Set virt-who to non-background mode(VIRTWHO_BACKGROUND=0), Then restart virt-who, it can't be started.

Version-Release number of selected component (if applicable):
subscription-manager-1.10.6-1.el7.x86_64
python-rhsm-1.10.6-1.el7.x86_64
virt-who-0.8-8.el7.noarch

How reproducible:
Always

Steps to Reproduce:
1. Prepare RHEL7.0 with latest subscription-manager and virt-who installed. 

2. On the terminal1: Configure virt-who isn't in background mode as the following:
[root@hp-z220-03 ~]# cat /etc/sysconfig/virt-who 
    VIRTWHO_BACKGROUND=0
    # Enable debugging output.
    VIRTWHO_DEBUG=1
    VIRTWHO_INTERVAL=20 
[root@dhcp-65-83 /]# systemctl start virt-who

3. On the terminal2: Check the virt-who status
[root@dhcp-65-175 ~]# systemctl status virt-who
virt-who.service - Daemon for reporting virtual guest IDs to subscription-manager
   Loaded: loaded (/usr/lib/systemd/system/virt-who.service; disabled)
   Active: activating (start) since Mon 2013-12-02 20:52:42 CST; 1min 19s ago
  Control: 3515 (python)
   CGroup: /system.slice/virt-who.service
           └─3515 /usr/bin/python /usr/share/virt-who/virt-who.py
Dec 02 20:52:42 dhcp-65-175.nay.redhat.com python[3515]: Virt-who is running in libvirt mode
Dec 02 20:52:42 dhcp-65-175.nay.redhat.com python[3515]: Starting infinite loop with 20 seconds interval
Dec 02 20:52:42 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:52:42 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:53:02 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:53:02 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:53:23 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:53:23 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:53:44 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:53:44 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []

4. After about 80s , check the virt-who status
[root@dhcp-65-175 ~]# systemctl status virt-who
virt-who.service - Daemon for reporting virtual guest IDs to subscription-manager
   Loaded: loaded (/usr/lib/systemd/system/virt-who.service; disabled)
   Active: failed (Result: timeout) since Mon 2013-12-02 20:54:12 CST; 10s ago
  Process: 3515 ExecStart=/usr/bin/virt-who (code=exited, status=0/SUCCESS)
Dec 02 20:53:02 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:53:23 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:53:23 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:53:44 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:53:44 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:54:04 dhcp-65-175.nay.redhat.com virt-who[3515]: DEBUG: Sending list of uuids: []
Dec 02 20:54:04 dhcp-65-175.nay.redhat.com python[3515]: Sending list of uuids: []
Dec 02 20:54:12 dhcp-65-175.nay.redhat.com systemd[1]: virt-who.service operation timed out. Terminating.
Dec 02 20:54:12 dhcp-65-175.nay.redhat.com systemd[1]: Failed to start Daemon for reporting virtual guest IDs to subscription-manager.
Dec 02 20:54:12 dhcp-65-175.nay.redhat.com systemd[1]: Unit virt-who.service entered failed state.

Actual results:
After step2, it hasn't any virt-who log message pop up on the terminal1, virt-who has hang up
After step4, virt-who start failed and it pop up error message on the terminal1:
[root@dhcp-65-175 ~]# systemctl start virt-who
Job for virt-who.service failed. See 'systemctl status virt-who.service' and 'journalctl -xn' for details.

Expected results:
After step2: virt-who log should be pop up on the terminal1
After step4: virt-who should be start successfully. and it shouldn't pop up any error messages on the terminal1.

Additional info:
RHEL6.5-RC-1.2(20131105.6)-Server-x86_64(virt-who-0.8-9.el6.noarch) hasn't this problem
RHEL6.4-20130130.0-Server-x86_64(virt-who-0.8-5.el6.noarch) also hasn't this problem

Comment 2 Radek Novacek 2013-12-04 08:02:34 UTC
Running virt-who in non-background mode with systemd doesn't make sense. I will remove the VIRTWHO_BACKGROUND option from the configuration file and will ignore this environmental variable at all.

Comment 3 Radek Novacek 2013-12-12 08:37:19 UTC
Fixed in virt-who-0.8-10.el7.

Comment 5 Liushihui 2013-12-20 09:22:18 UTC
Verified on Rhel7.0-20131219.0(virt-who-0.8-10.el7), VIRTWHO_BACKGROUND option has been removed from the configuration file.

Comment 6 Ludek Smid 2014-06-13 10:39:22 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


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