-
Story
-
Resolution: Won't Do
-
Undefined
-
None
-
None
-
None
-
None
-
subs-client-tools
-
None
-
False
-
False
-
-
None
-
None
-
None
-
None
-
Unspecified
-
Unspecified
-
Unspecified
-
None
Goal
The 'subscription-manager' must assign the IPv4 address (management IPv4 address on which system hostname resolves and could be connected from external network) of interface to which the system hostname resolves as the value for "net.interface.<interface>.ipv4_address_list" variable in the subscription-manager facts.
The 'subscription-manager' currently collects all the IPv4 addresses assigned to the interface and list them under the subscription-manager facts with a variable as "net.interface.<interface>.ipv4_address_list". At the same time, the first IPv4 address in the list of collected IPv4 addresses is reported as Primary IP with the "net.interface.<interface>.ipv4_address" variable.
e.g. # ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16384 qdisc noqueue state UNKNOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 link/ether xx:xx:xx:xx:xx:xx brd ff:ff:ff:ff:ff:ff inet 10.x.x.6/24 brd 10.x.x.255 scope global noprefixroute eth0:hb1 <-------- frist IPv4 address (Heart beat IP address) valid_lft forever preferred_lft forever inet 10.x.x.X/24 brd 10.x.x.255 scope global noprefixroute eth0 <-------- Management IPv4 address (IP address to which system hostname resolves) valid_lft forever preferred_lft forever inet 10.x.x.151/24 brd 10.x.x.255 scope global secondary eth0:1 valid_lft forever preferred_lft forever # subscription-manager facts | grep -i eth[0-9].ipv4 net.interface.eth0.ipv4_address: 10.x.x.6 <<------- Primary IPv4 address for eth0 net.interface.eth0.ipv4_address_list: 10.x.x.6, 10.x.x.137, 10.x.x.151 <<------- list of IPv4 addressess assigned to the eth0.
With the current logic, subscription-manager simply picks the first IPv4 in the list of IPv4 addresses assigned to an interface as the value for the fact "net.interface.<interface>.ipv4_address". The subscription-manager fact variable "net.interface.<interface>.ipv4_address" is responsible for reporting its value as Primary IP in the Satellite UI for RHEL client when registered to the Satellite server.
The subscription-manager should consider the management IPv4 address (IPv4 address to which system resolves from external network as well) as the primary address to assign to the facts variable "net.interface.<interface>.ipv4_address" so that when system is registered to the Satellite server, this IP should appear there as Primary IP. This is needed in a situation when the remote execution jobs are run via Satellite on client systems and if the Management IPv4 addreess is not Primary IP reported in the Satellite UI, remote execution fails as system can not reach to non-management IPv4 address.
In the customer's case, the first IP address '10.x.x.6/24' assigned to the interface 'eth0' is Heart beat IPv4 address, and it is an internal IPv4 address. The system can not resolve to this address from the external network. There are hundreds of such servers (and many to be deployed in the future) in the customer's environment where the first IPv4 address assigned to the interface is the Heart beat IP address and it's a common IP address for all the systems. Therefore, whenever these systems are registered to the Satellite, all systems are reporting this Heart beat IPv4 address as Primary IP in the satellite UI. Having the Management IPv4 address reported as Primary IP instead of the common Heart beat IP will help the customer to perform successful remote execution from Satellite UI.
When subscription-manager collects a list of IPv4 addresses assigned to the interface, instead of considering the first IPv4 address in the list as the value to "net.interface.<interface>.ipv4_address" variable, subscription-manager must determine the Management IP ( IP to which the system hostname can resolve and can be connected from the external network as well). e.g. in the current set-up, the management IP on the system could be determined via the command # ip route get 1.1.1.1. However, the best possible and suitable way should be considered to implement this.
Acceptance criteria
When the logic is implemented as expected, making the subscription-manager to determine the Management IP address and assigning this address to the fact variable "net.interface.<interface>.ipv4_address", it can be verified by checking subscription-manager facts. Also, the system can be registered to the satellite server, and reported Primary IP can be verified in Satellite UI.