Use FQDN for memcached
After the management network reconfig the memcached was still using the old mgmt IP after the unlock. The new mgmt network is applied by puppet during the system startup, it is executed by the controller_config script. Until the puppet reconfigures the system the /etc/hosts was not updated, and the IPs for hostname was the old one. The memcached is started by init.d and was using the hostname, it was starting before the /etc/hosts update. Using the FQDN, this problem doesn't occurs, the memcached will start but will just get the IP after the dnsmasq starts. Tests done: IPv4 AIO-SX fresh install IPv4 AIO-DX fresh install IPv4 DC with AIO-SX subcloud fresh install IPv4 AIO-SX mgmt network reconfig IPv4 DC with AIO-SX subcloud mgmt network reconfig Story: 2010722 Task: 49743 Change-Id: I810189638275a09127c3c228aeeb3416731d350d Signed-off-by: Fabiano Correa Mercer <fabiano.correamercer@windriver.com>
This commit is contained in:
parent
df267e75c0
commit
c1aec0b159
|
@ -10,10 +10,12 @@ class platform::memcached::params(
|
|||
$service_restart = true,
|
||||
) {
|
||||
include ::platform::params
|
||||
$controller_0_hostname = $::platform::params::controller_0_hostname
|
||||
$controller_1_hostname = $::platform::params::controller_1_hostname
|
||||
$system_mode = $::platform::params::system_mode
|
||||
$system_type = $::platform::params::system_type
|
||||
$controller_0_hostname = $::platform::params::controller_0_hostname
|
||||
$controller_1_hostname = $::platform::params::controller_1_hostname
|
||||
$controller_0_fqdn = $::platform::params::controller_0_fqdn
|
||||
$controller_1_fqdn = $::platform::params::controller_1_fqdn
|
||||
$system_mode = $::platform::params::system_mode
|
||||
$system_type = $::platform::params::system_type
|
||||
|
||||
if $system_type == 'All-in-one' and
|
||||
$::platform::params::distributed_cloud_role != 'systemcontroller' {
|
||||
|
@ -23,14 +25,14 @@ class platform::memcached::params(
|
|||
}
|
||||
|
||||
if $system_mode == 'simplex' {
|
||||
$listen = $controller_0_hostname
|
||||
$listen = $controller_0_fqdn
|
||||
} else {
|
||||
case $::hostname {
|
||||
$controller_0_hostname: {
|
||||
$listen = $controller_0_hostname
|
||||
$listen = $controller_0_fqdn
|
||||
}
|
||||
$controller_1_hostname: {
|
||||
$listen = $controller_1_hostname
|
||||
$listen = $controller_1_fqdn
|
||||
}
|
||||
default: {
|
||||
fail("Hostname must be either ${controller_0_hostname} or ${controller_1_hostname}")
|
||||
|
|
Loading…
Reference in New Issue