Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite 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 "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. 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 "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-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.
DescriptionVaratharaja Perumal G
2019-08-22 10:49:39 UTC
Description of problem:
When we have the DHCP capsule server behind a firewall and the requests from port 7 which is used for checking the TCP pingable on free IP is refused. Satellite considers the IP address is used and it failed to provide the free IP (autosuggest).
Version-Release number of selected component (if applicable):
Red Hat Satellite 6.4
Actual results:
Satellite capsule failed to provide free IP.
Expected results:
Satellite should use ping if it fails with TCP.
Additional info:
pingable code file:-
"/usr/share/foreman-proxy/modules/dhcp_common/free_ips.rb"
~~~
logger.debug "Searching for free IP - pinging #{possible_ip}."
if tcp_pingable?(possible_ip) || icmp_pingable?(possible_ip)
logger.debug "Found a pingable IP(#{possible_ip}) address
which does not have a Proxy::DHCP record."
else
logger.debug "Found free IP #{possible_ip} out of a total
of #{num_of_addresses} free IPs."
return possible_ip
end
~~~
As the connection is refused satellite consider the IPs is pingable
even if its free.
Tested modified code:-
~~~
logger.debug "Searching for free IP - pinging #{possible_ip}."
if !tcp_pingable?(possible_ip)
logger.debug "Found free IP #{possible_ip} out of a total
of #{num_of_addresses} free IPs."
return possible_ip
elsif !icmp_pingable?(possible_ip)
logger.debug "Found free IP #{possible_ip} out of a total
of #{num_of_addresses} free IPs."
return possible_ip
else
logger.debug "Found a pingable IP(#{possible_ip}) address
which does not have a Proxy::DHCP record."
end
~~~
Tested on Sat 6.7 Snap 10 using following steps:
1. create an isolated network managed by a separate capsule with DHCP enabled, with a very small DHCP range (e.g. a pool of 5 addresses)
2. connect a client to the network and manually assign an address (which is not leased out by the DHCP server, of course) from the DHCP range to it
3. run a manual creation of a new host on the Satellite, assign the host to the isolated network, and click the "Suggest new" link a few times.
With ping_free_ip: true
Satellite will suggest addresses not leased out by the DHCP server, and WILL NOT suggest the address manually assigned in the step 2, because it has been pinged and determined as taken in the real-time.
With ping_free_ip: false
Satellite will suggest addresses not leased out by the DHCP server, and WILL suggest the address manually assigned in the step 2, because the DHCP db is its only source of info, and no checking pings are made.
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/RHSA-2020:1454
Description of problem: When we have the DHCP capsule server behind a firewall and the requests from port 7 which is used for checking the TCP pingable on free IP is refused. Satellite considers the IP address is used and it failed to provide the free IP (autosuggest). Version-Release number of selected component (if applicable): Red Hat Satellite 6.4 Actual results: Satellite capsule failed to provide free IP. Expected results: Satellite should use ping if it fails with TCP. Additional info: pingable code file:- "/usr/share/foreman-proxy/modules/dhcp_common/free_ips.rb" ~~~ logger.debug "Searching for free IP - pinging #{possible_ip}." if tcp_pingable?(possible_ip) || icmp_pingable?(possible_ip) logger.debug "Found a pingable IP(#{possible_ip}) address which does not have a Proxy::DHCP record." else logger.debug "Found free IP #{possible_ip} out of a total of #{num_of_addresses} free IPs." return possible_ip end ~~~ As the connection is refused satellite consider the IPs is pingable even if its free. Tested modified code:- ~~~ logger.debug "Searching for free IP - pinging #{possible_ip}." if !tcp_pingable?(possible_ip) logger.debug "Found free IP #{possible_ip} out of a total of #{num_of_addresses} free IPs." return possible_ip elsif !icmp_pingable?(possible_ip) logger.debug "Found free IP #{possible_ip} out of a total of #{num_of_addresses} free IPs." return possible_ip else logger.debug "Found a pingable IP(#{possible_ip}) address which does not have a Proxy::DHCP record." end ~~~