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 1542652 - virt-who -c filename do not parse only the specified filename
Summary: virt-who -c filename do not parse only the specified filename
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-who
Version: 7.4
Hardware: x86_64
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Nikos Moumoulidis
QA Contact: Eko
URL:
Whiteboard:
: 1391913 1626243 (view as bug list)
Depends On:
Blocks: 1353215
TreeView+ depends on / blocked
 
Reported: 2018-02-06 17:58 UTC by Daniele Palumbo
Modified: 2022-03-13 14:41 UTC (History)
14 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-30 10:47:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github candlepin virt-who pull 141 0 None closed 1542652: When the -c option is used, don't parse the default files 2020-07-13 03:43:18 UTC
Red Hat Product Errata RHBA-2018:3169 0 None None None 2018-10-30 10:48:17 UTC

Description Daniele Palumbo 2018-02-06 17:58:05 UTC
Description of problem:
virt-who -c help to specify a dedicated configuration file to be parsed.
Using -c option, all of the configuration specified in virt-who.conf and virt-who.d/* are parsed as well.


Version-Release number of selected component (if applicable):
RHEL 7.4, virt-who-0.19-7.el7_4.noarch

How reproducible:
Always

Steps to Reproduce:
1. write some virt-who entry in /etc/virt-who.conf file or in /etc/virt-who.d/*.conf file
2. run virt-who -c /otherpath/file

Actual results:
Currently virt-who will add all of the configuration from virt-who.conf and virt-who.d, plus the configuration from -c command line option

Expected results:
Only the -c file should be parsed.


Additional info:

From the man VIRT-WHO-CONFIG(5)                                                 
"""                         
  -c CONFIGS, --config=CONFIGS
                        Configuration file that will be processed, can be used
                        multiple times
"""
There is no mention to parsing (or not) of defaults files.

The problem should be likely addressed at 
https://github.com/virt-who/virt-who/blob/744a6c9f39b01a3a1a42f691ef3971f5ecc5fabd/virtwho/config.py#L1376
While for RHEL 7.4 should be in config.py, line 530
"""
        try:
            all_dir_content = set(os.listdir(config_dir))
"""

HTH

Comment 3 Kevin Howell 2018-02-08 15:32:27 UTC
Workaround is to rename/move config files temporarily. Recent versions of virt-who (virt-who-0.19-5 or newer) will ignore files whose names don't end in ".conf"...

Comment 7 Kenny Tordeurs 2018-06-05 08:08:51 UTC
*** Bug 1391913 has been marked as a duplicate of this bug. ***

Comment 11 Hradayesh Shukla 2018-10-02 21:55:40 UTC
*** Bug 1626243 has been marked as a duplicate of this bug. ***

Comment 13 errata-xmlrpc 2018-10-30 10:47:49 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/RHBA-2018:3169


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