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 1314175 - virt-who can't terminate automatically when run with error username/password
Summary: virt-who can't terminate automatically when run with error username/password
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: virt-who
Version: 6.8
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: rc
: ---
Assignee: Chris Snyder
QA Contact: Eko
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-03-03 07:49 UTC by Liushihui
Modified: 2016-12-15 07:54 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-15 07:54:17 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Liushihui 2016-03-03 07:49:10 UTC
Description of problem:
When run virt-who with wrong hypervisor username and password, it still run normally although throw up error info in the log.

Version-Release number of selected component (if applicable):
virt-who-0.16-5.el6.noarch
subscription-manager-1.16.8-3.el6.x86_64
python-rhsm-1.16.6-1.el6.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Register system to satellite6
2. Run virt-who with error username and password at CLI mode:
[root@sgi-xe270-01 ~]# virt-who --hyperv --hyperv-owner=ACME_Corporation --hyperv-env=Library --hyperv-server=10.73.5.227 --hyperv-username=administrator --hyperv-password=XXXXXXX 
2016-03-03 02:41:49,700 INFO: Using reporter_id='sgi-xe270-01.rhts.eng.bos.redhat.com'
2016-03-03 02:41:49,703 INFO: Using configuration "env/cmdline" ("hyperv" mode)
2016-03-03 02:41:53,300 ERROR: Virt backend 'env/cmdline' fails with error: Incorrect domain/username/password
2016-03-03 02:41:53,301 INFO: Waiting 60 seconds before retrying backend 'env/cmdline'
2016-03-03 02:42:56,808 ERROR: Virt backend 'env/cmdline' fails with error: Incorrect domain/username/password
2016-03-03 02:42:56,808 INFO: Waiting 60 seconds before retrying backend 'env/cmdline'

Actual results:
Although it will throw up error info "fails with error: Incorrect domain/username/password" virt-who thread can't terminated automatically,it still retry every 60s,

Expected results:
When username and password is error, virt-who should not only throw up error info in the log but also terminated automatically.

Additional info:

Comment 2 Radek Novacek 2016-05-05 09:12:29 UTC
I don't think virt-who should terminate itself in this case, there are couple of scenarios to consider:

1) admin first starts virt-who and after that creates user in the hypervisor
2) temporary outage in authentication mechanism on hypervisor (e.g. when LDAP server is not available for some time and hypervisor tries to authenticate against local users)

Overall I think that virt-who shouldn't stop when hypervisor username/password is not valid. 

Opinions?

Comment 3 Radek Novacek 2016-10-06 07:44:15 UTC
Liushihui,

do you agree with my reasoning in comment #2?

Comment 4 Liushihui 2016-10-18 08:48:52 UTC
Redak,

OK, I understand it now.
However, I have another concern about this problem since virt-who throw up some exception info when it failed to connect vcenter. please see it as the following. 
Can virt-who just send some brief error info as it show on hyperv(Incorrect domain/username/password)? 

2016-10-18 04:43:17,765 [virtwho.test-esx1 ERROR] Esx-1(23748):MainThread @esx.py:login:346 - Unable to login to ESX
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/virtwho/virt/esx/esx.py", line 341, in login
    self.client.service.Login(_this=self.sc.sessionManager, userName=self.username, password=self.password)
  File "/usr/lib/python2.7/site-packages/suds/client.py", line 542, in __call__
    return client.invoke(args, kwargs)
  File "/usr/lib/python2.7/site-packages/suds/client.py", line 602, in invoke
    result = self.send(soapenv)
  File "/usr/lib/python2.7/site-packages/suds/client.py", line 647, in send
    result = self.succeeded(binding, reply.message)
  File "/usr/lib/python2.7/site-packages/suds/client.py", line 684, in succeeded
    reply, result = binding.get_reply(self.method, reply)
  File "/usr/lib/python2.7/site-packages/suds/bindings/binding.py", line 151, in get_reply
    self.detect_fault(soapbody)
  File "/usr/lib/python2.7/site-packages/suds/bindings/binding.py", line 182, in detect_fault
    raise WebFault(p, fault)
WebFault: Server raised fault: 'Cannot complete login due to an incorrect user name or password.'

Comment 5 Eko 2016-12-15 07:54:17 UTC
closed it, if exception error is still exist, please file a new bug for it.


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