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 1412425 - [RFE] python-rhsm should provide a default proxy_port
Summary: [RFE] python-rhsm should provide a default proxy_port
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: python-rhsm
Version: 7.0
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: pre-dev-freeze
: ---
Assignee: candlepin-bugs
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-12 01:58 UTC by Liushihui
Modified: 2020-04-14 12:45 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-04-14 12:45:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Liushihui 2017-01-12 01:58:26 UTC
Description of problem:
When it hasn't configure rhsm_proxy_port in /etc/virt-who.d/XXX, virt-who won't check rhsm_proxy_hostname.

Version-Release number of selected component (if applicable):
Satellite6.2.7
virt-who-0.17-10.el6sat.noarch

How reproducible:
Always

Steps to Reproduce:
1. Configure virt-who with a wrong proxy in /etc/virt-who.d/xxx
[root@hp-z220-05 virt-who.d]# cat /etc/virt-who.d/hyperv 
[test-hyperv1]
type=hyperv
server=10.73.5.227
username=administrator
password="Welcome*&$001"
owner=org1
env=Library 
rhsm_username=admin
rhsm_encrypted_password=7cb1ad2bcbd186c9d9cb6a391361e6ea
rhsm_hostname=hp-bl460cg5-01.rhts.eng.bos.redhat.com
rhsm_port=443
rhsm_prefix=/rhsm
rhsm_proxy_hostname=aaaa               ===> It's wrong

2. Restart virt-who and check virt-who's log
[root@hp-z220-05 virt-who.d]# service virt-who restart && tail -f /var/log/rhsm/rhsm.log

Actual results:
Virt-who can send mapping info to satellite server successfully, it hasn't check rhsm_proxy_hostname.

Expected results:
As it's a wrong rhsm_proxy_hostname, virt-who shouldn't send mapping info to satellite server, it should show error info to remind " Name or service not known"

Additional info:
If configure rhsm_proxy_hostname and rhsm_proxy_host in /etc/virt-who.d/xxx, it can show error info as the following:
"gaierror: [Errno -2] Name or service not known"

Comment 4 Chris Snyder 2017-05-11 20:16:33 UTC
This is a result of the implementation of the UEPConnection in python-rhsm used by virt-who to communicate with Satellite (as well as hosted).

I do not believe this is a bug.

As such I am closing this.

If there is disagreement, please reopen the bug with details as to why this is actually a bug.

Comment 5 Liushihui 2017-05-15 01:45:36 UTC
I think it still is a bug since it should has a default "rhsm_proxy_port" if "rhsm_proxy_port" hasn't be set. 
Actually, we can compare a similar pair of configure "rhsm_hostname and rhsm_port".
1. If it hasn't set "rhsm_port", configure wrong "rhsm_hostname", it will show error info "Name or service not known" since it should has a default "rhsm_port=443", it's the correct behavior.
2. If it hasn't set "rhsm_port", configure correct "rhsm_hostname", it will send mapping info to server,it's the correct behavior.

So I expect the "rhsm_proxy_port and rhsm_proxy_hostname" should have the same behavior as "rhsm_hostname and rhsm_port". 

Therefore, I reopen it. Thanks.


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