Bug 1420533
| Summary: | no_proxy environment variable is ignored by the rhsmd process | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | John Sefler <jsefler> |
| Component: | python-rhsm | Assignee: | Kevin Howell <khowell> |
| Status: | CLOSED ERRATA | QA Contact: | John Sefler <jsefler> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 7.3 | CC: | bcourt, redakkan, skallesh |
| Target Milestone: | rc | Keywords: | Triaged |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | subscription-manager-1.19.6-1.el7 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2017-08-01 19:20:42 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
John Sefler
2017-02-08 22:01:41 UTC
Still see tail of both rhsm.log and /var/log/squid/access.log has some traffic proxy server, so marking bug as failed_qa [root@dhcp35-160 ~]# subscription-manager version server type: Red Hat Subscription Management subscription management server: 0.9.51.21-1 subscription management rules: 5.15.1 subscription-manager: 1.19.7-1.el7 python-rhsm: 1.19.4-1.el7 [root@dhcp35-160 ~]# [root@dhcp35-160 ~]# subscription-manager clean All local data removed [root@dhcp35-160 ~]# NO_PROXY="*" subscription-manager register --username=qa Registering to: subscription.rhsm.stage.redhat.com:443/subscription Password: The system has been registered with ID: 5b5a08ab-275e-4566-8f98-355779cbb1b2 [root@dhcp35-160 ~]# tail -f /var/log/rhsm/rhsm.log | grep proxy 2017-04-17 13:39:46,071 [INFO] rhsmd:26245:MainThread @connection.py:774 - Connection built: http_proxy=auto-services.usersys.redhat.com:3128 host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=identity_cert ca_dir=/etc/rhsm/ca/ insecure=False [root@auto-services ~]# tail -f /var/log/squid/access.log 1492416483.670 1520 10.70.35.160 TCP_MISS/200 3549 CONNECT subscription.rhsm.stage.redhat.com:443 redhat HIER_DIRECT/10.24.204.73 - Shwetha, actually, this test scenario needs to be revised. There is not an easy way to get rhsmd to respect environment variables, so the solution implemented was to allow specifying no_proxy in /etc/rhsm/rhsm.conf. The test scenario should involve setting no_proxy in the config file, not as an environment variable. Sorry that we didn't convey this in the BZ until now. The original scenario presented in comment 0 will continue to fail. A customer who needs to use no_proxy should specify it in the config file. [root@dhcp71-191 ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.21-1
subscription management rules: 5.15.1
subscription-manager: 1.19.12-1.el7
python-rhsm: 1.19.6-1.el7
Before setting no_proxy variable in /etc/rhsm/rshm.conf file
[root@dhcp71-191 ~]# NO_PROXY="*" subscription-manager register --username=shwetha_tier1_test
Registering to: subscription.rhsm.stage.redhat.com:443/subscription
Password:
The system has been registered with ID: 7451c8d4-7ee5-4cc1-9302-5b8c42db0882
[root@dhcp71-191 ~]# tail -f /var/log/rhsm/rhsm.log | grep proxy
2017-05-03 08:14:19,402 [INFO] rhsmd:24173:MainThread @connection.py:780 - Connection built: http_proxy=auto-services.usersys.redhat.com:3128 host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=identity_cert ca_dir=/etc/rhsm/ca/ insecure=False
return self._proxy_method(*args, **keywords)
[root@auto-services ~]# tail -f /var/log/squid/access.log
1493813530.657 539 10.16.71.191 TCP_MISS/200 3392 CONNECT subscription.rhsm.stage.redhat.com:443 redhat HIER_DIRECT/10.24.204.73 -
After setting no_proxy variable to "*" in rhsm.conf file
[root@dhcp71-191 ~]# subscription-manager config --server.hostname=subscription.rhsm.stage.redhat.com --server.port=443 --server.prefix=/subscription --server.proxy_hostname=auto-services.usersys.redhat.com --server.proxy_port=3128 --server.proxy_user=redhat --server.proxy_password=redhat
[root@dhcp71-191 ~]# subscription-manager config --server.no_proxy=*
[root@dhcp71-191 ~]# subscription-manager register --username=shwetha_tier1_test
Registering to: subscription.rhsm.stage.redhat.com:443/subscription
Password:
The system has been registered with ID: f1704c71-ac46-4464-987f-f89e07f6b29e
[root@dhcp71-191 ~]# tail -f /var/log/rhsm/rhsm.log | grep proxy
[root@auto-services ~]# tail -f /var/log/squid/access.log
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-2017:2083 |