Hide Forgot
Description of problem: proxy_port settings from rhsm.conf are not respected by subscription manager. Version-Release number of selected component (if applicable): subscription-manager-1.20.11-1.el7_5.x86_64 subscription-manager-rhsm-1.20.11-1.el7_5.x86_64 How reproducible: Steps to Reproduce: 1. set proxy in rhsm.conf proxy_port = 8080 (different than 3128) and proxy host 2. try to register with satellite Actual results: Default proxy port is used. connect(6, {sa_family=AF_INET, sin_port=htons(3128), sin_addr=inet_addr("XXXX")}, 16) = -1 EINPROGRESS (Operation now in progress) Proxy connection failed, please check your settings. Expected results: Honoring proxy port settings and registering with satellite. Additional info: Pull request for upstream provided - https://github.com/candlepin/subscription-manager/pull/1816
Command line used to run subscription-manager /sbin/subscription-manager register --force --baseurl XXX --serverurl XXX --org XXX --activationkey XXX
Reproducer: [root@hp-dl380pgen8-02-vm-13 ~]# subscription-manager version server type: This system is currently not registered. subscription management server: 2.2.3-1 subscription management rules: 5.26 subscription-manager: 1.20.10-1.el7 [root@hp-dl380pgen8-02-vm-13 ~]# strace -e connect -ff /sbin/subscription-manager register --org="*******" --activationkey="rhel7server_ak" --serverurl ********:443/rhsm --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=28824, si_uid=0, si_status=0, si_utime=0, si_stime=0} --- connect(4, {sa_family=AF_LOCAL, sun_path="/run/dbus/system_bus_socket"}, 29) = 0 connect(7, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("10.16.36.29")}, 16) = 0 connect(6, {sa_family=AF_INET, sin_port=htons(3128), sin_addr=inet_addr("10.12.6.121")}, 16) = -1 EINPROGRESS (Operation now in progress) Proxy connection failed, please check your settings.
Verification: [root@localhost ~]# subscription-manager version server type: Red Hat Subscription Management subscription management server: 3.7.0.7-Unknown subscription management rules: 5.26 subscription-manager: 1.21.5-7.el7 [root@localhost ~]# cat /etc/rhsm/rhsm.conf | grep proxy_port proxy_port = 3129 [root@localhost ~]# strace -e connect -ff /sbin/subscription-manager register --org="******" --activationkey="rhel7server_ak" --serverurl **********:443/rhsm --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=13529, si_uid=0, si_status=0, si_utime=0, si_stime=0} --- connect(5, {sa_family=AF_LOCAL, sun_path="/run/dbus/system_bus_socket"}, 29) = 0 connect(7, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("10.75.5.25")}, 16) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(3129), sin_addr=inet_addr("10.12.6.121")}, 16) = -1 EINPROGRESS (Operation now in progress) connect(3, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("10.75.5.25")}, 16) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(3129), sin_addr=inet_addr("10.12.6.121")}, 16) = -1 EINPROGRESS (Operation now in progress) --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=13569, si_uid=0, si_status=0, si_utime=0, si_stime=0} --- connect(3, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0 connect(3, {sa_family=AF_INET6, sin6_port=htons(0), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("10.75.5.25")}, 16) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(3129), sin_addr=inet_addr("10.12.6.121")}, 16) = -1 EINPROGRESS (Operation now in progress) connect(3, {sa_family=AF_LOCAL, sun_path="/dev/log"}, 110) = 0 The system has been registered with ID: b38f2256-4152-478e-b9af-d7e5f985fa1e The registered system name is: localhost.localdomain
Marie, As currently written, the doc text is not conveying the information that the user needs to know. Let's try again.... Subscription manager does not respect `proxy_port` settings from rhsm.conf Subscription manager does not respect changes to the default `proxy_port` configuration from /etc/rhsm/rhsm.conf. Even after the user changed the value of `proxy_port`, the default value of 3128 was continually being used. This bug has now been fixed. However, making any change to the proxy_port value in /etc/rhsm/rhsm.conf will likely require an selinux policy change. The user should run this additional step for the benefit of the `rhsmcertd` daemon process to avoid selinux denials whenever changing the default `proxy_port` configuration away from 3128. semanage port -a -t squid_port_t -p tcp <new_proxy_port>
(In reply to John Sefler from comment #8) > Marie, > As currently written, the doc text is not conveying the information that the > user needs to know. Let's try again.... > > > Subscription manager does not respect `proxy_port` settings from rhsm.conf > > Subscription manager does not respect changes to the default `proxy_port` > configuration from /etc/rhsm/rhsm.conf. Even after the user changed the > value of `proxy_port`, the default value of 3128 was continually being used. > > This bug has now been fixed. However, making any change to the proxy_port > value in /etc/rhsm/rhsm.conf will likely require an selinux policy change. > The user should run this additional step for the benefit of the `rhsmcertd` > daemon process to avoid selinux denials whenever changing the default > `proxy_port` configuration away from 3128. > > semanage port -a -t squid_port_t -p tcp <new_proxy_port> Hi John, Thanks a lot for the review and text provided. I modified it a little bit to meet our documentation conventions. I just put the beginning into the past tense - if I understand it well, it was previous behavior (the bug) that was fixed so it's not happening now and should be in the past tense. Is that correct? Thank you! Marie
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:3153