Bug 1507449 - osm_controller_lease_ttl setting is not honored
Summary: osm_controller_lease_ttl setting is not honored
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 3.7.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ---
: 3.7.0
Assignee: Michael Gugino
QA Contact: Johnny Liu
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-10-30 09:54 UTC by Johnny Liu
Modified: 2017-11-28 22:20 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-11-28 22:20:01 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2017:3188 0 normal SHIPPED_LIVE Moderate: Red Hat OpenShift Container Platform 3.7 security, bug, and enhancement update 2017-11-29 02:34:54 UTC

Description Johnny Liu 2017-10-30 09:54:50 UTC
Description of problem:
According to https://github.com/openshift/openshift-ansible/blob/master/inventory/byo/hosts.example#L314, setting osm_controller_lease_ttl=10 in inventory host file, trigger a multiple master ha env installation, after installation, go to /etc/origin/master/master-config.yaml, found, no "controllerLeaseTTL" is set there. 

Go to openshift-ansible code, found the following lines are missing from roles/openshift_master/templates/master.yaml.v1.j2:
{% if openshift_master_ha | bool %}
controllerLeaseTTL: {{ openshift.master.controller_lease_ttl | default('30') }}
{% endif %}

This change is introduced by https://github.com/openshift/openshift-ansible/pull/4832. 

Understanding from me, controllerLeaseTTL is used for controller lease ttl, not relative to separate api and controllers services, am I right?

If my understanding is wrong, this change is by design, at least we need update hosts.example to tell users.


Version-Release number of the following components:
openshift-ansible-3.7.0-0.184.0.git.0.d407445.el7.noarch
How reproducible:

Steps to Reproduce:
1.
2.
3.

Actual results:
Please include the entire output from the last TASK line through the end of output if an error is generated

Expected results:

Additional info:
Please attach logs from ansible-playbook with the -vvv flag

Comment 1 Scott Dodson 2017-10-30 13:35:57 UTC
We should probably consider ensuring that openshift_master_ha is set to true no matter what in 3.7 installs and/or look to get rid of all conditional logic based on its value.

Comment 2 Michael Gugino 2017-10-31 16:02:54 UTC
We should remove that from the docs.  It looks like that setting is ignored if controllerConfig.election is defined.

That was added in the same PR, here: https://github.com/openshift/openshift-ansible/pull/4832/files#diff-aedb994b078d72553713e06204255f38R52

from origin/pkg/cmd/server/api/v1/swagger_doc.go

'var map_ControllerConfig = map[string]string{
        "":                   "ControllerConfig holds configuration values for controllers",
        "election":           "Election defines the configuration for electing a controller instance to make changes to the cluster. If unspecified, the ControllerTTL value is checked to determine whether the legacy direct etcd election code will be used.",
        "serviceServingCert": "ServiceServingCert holds configuration for service serving cert signer which creates cert/key pairs for pods fulfilling a service to serve with.",
}

func (ControllerConfig) SwaggerDoc() map[string]string {
        return map_ControllerConfig
}

var map_ControllerElectionConfig = map[string]string{
        "":              "ControllerElectionConfig contains configuration values for deciding how a controller will be elected to act as leader.",
        "lockName":      "LockName is the resource name used to act as the lock for determining which controller instance should lead.",
        "lockNamespace": "LockNamespace is the resource namespace used to act as the lock for determining which controller instance should lead. It defaults to \"kube-system\"",
        "lockResource":  "LockResource is the group and resource name to use to coordinate for the controller lock. If unset, defaults to \"configmaps\".",
}
'

origin also denotes that ControllerTTL is deprecated and will be removed in 3.9.

Comment 3 Michael Gugino 2017-10-31 16:23:59 UTC
PR Created: https://github.com/openshift/openshift-ansible/pull/5949

Comment 5 Johnny Liu 2017-11-03 03:25:51 UTC
Verified this bug with openshift-ansible-docs-3.7.0-0.190.0.git.0.129e91a.el7.noarch, osm_controller_lease_ttl description is removed from hosts.example.

Comment 8 errata-xmlrpc 2017-11-28 22:20:01 UTC
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-2017:3188


Note You need to log in before you can comment on or make changes to this bug.