Bug 1684357 - [DOCS] Master configuration not updated in "Resource quotas per project" page
Summary: [DOCS] Master configuration not updated in "Resource quotas per project" page
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Documentation
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: 4.1.z
Assignee: Andrea Hoffer
QA Contact: Xingxing Xia
Vikram Goyal
URL:
Whiteboard: 4.1.2
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-03-01 04:34 UTC by Xingxing Xia
Modified: 2019-06-19 06:45 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-19 06:45:34 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:1382 0 None None None 2019-06-19 06:45:44 UTC

Description Xingxing Xia 2019-03-01 04:34:11 UTC
Document URL: 
https://docs.openshift.com/container-platform/4.0/applications/quotas/quotas-setting-per-project.html

1.
Section Number and Name: 
"Requiring explicit quota to consume a resource"

Describe the issue: 
a. Under "Add the following stanza to the master configuration", it still uses 3.x approach.
b. "Restart the master services to apply the changes:" still uses master-restart

Suggestions for improvement: 
a. Should use 4.0 approach which is managed by openshift-kube-apiserver-operator, see https://github.com/openshift/cluster-kube-apiserver-operator#configuration
b. Just need wait a moment, kube-apiserver pods will automatically restart once issue "a" is updated

2.
Section Number and Name: 
"Configuring quota synchronization period"

Describe the issue: 
The guide under "Change the resource-quota-sync-period" still uses 3.x approach to update "controllerArguments" of resource-quota-sync-period.

Suggestions for improvement: 
Should use 4.0 approach to update "controllerArguments" (still need investigate how to)

Additional information: 
Another minor issue: there is a "kubectl api-resources" in the page, should replace kubectl with oc

Comment 3 Andrea Hoffer 2019-04-08 17:25:50 UTC
Hi @Xingxing Xia, for 'Should use 4.0 approach to update "controllerArguments" (still need investigate how to)', do you have any information on the 4.x approach for updating "controllerArguments"? Thanks!

Comment 4 Xingxing Xia 2019-04-09 10:31:45 UTC
oc edit kubecontrollermanager cluster`:
...snipped, kept as it is...
  unsupportedConfigOverrides:
    extendedArguments:
      resource-quota-sync-period:
      - 60s
Save and exit.

Comment 5 Xingxing Xia 2019-04-09 10:32:56 UTC
Tips about it:
From another repo https://github.com/openshift/cluster-kube-apiserver-operator :
"The configuration for the Kubernetes API server is the result of merging:
    a default config
    observed config (compare observed values above) spec.spec.unsupportedConfigOverrides from the kubeapiserveroperatorconfig"

Thus let's check https://github.com/openshift/cluster-kube-controller-manager-operator for "controllerArguments", will get its "default config": https://github.com/openshift/cluster-kube-controller-manager-operator/blob/master/bindata/v3.11.0/kube-controller-manager/defaultconfig.yaml , notice the "extendedArguments" part.

Then let's check `oc get kubecontrollermanager cluster -o yaml` to see which are "observed config"
...
spec:
...
  observedConfig: # Below are the "observed config"
    extendedArguments:
      cloud-provider:
      - aws
      cluster-cidr:
      - 10.128.0.0/14
      service-cluster-ip-range:
      - 172.30.0.0/16
    serviceServingCert:
      certFile: /etc/kubernetes/static-pod-resources/configmaps/service-ca/ca-bundle.crt
  unsupportedConfigOverrides: null
...

From above, we know resource-quota-sync-period is not under "observedConfig". Thus, it should be under "unsupportedConfigOverrides". Let's set it under "unsupportedConfigOverrides" by `oc edit kubecontrollermanager cluster`:
...snipped, kept as it is...
  unsupportedConfigOverrides:
    extendedArguments:
      resource-quota-sync-period:
      - 60s
Save and exit.

Verification of above steps:
After oc edit, check `oc get po -n openshift-kube-controller-manager`, the kube-controller-manager-... pods will be recreated. Wait until they're running, then check the log:
$ oc logs -n openshift-kube-controller-manager kube-controller-manager-ip-172-31-140-231.ec2.internal > kcm.log
$ grep resource-quota-sync-period kcm.log
I0409 10:02:20.843268       1 flags.go:33] FLAG: --resource-quota-sync-period="1m0s"
^ This means above steps take effect.

Comment 6 Andrea Hoffer 2019-05-01 14:47:30 UTC
Hi @Xingxing,

For item 2 ("Configuring quota synchronization period"), I think I've updated the procedure appropriately, if you wouldn't mind taking a look at the preview here [1].

In what you listed for 1b, I didn't see master-restart for the "Requiring explicit quota to consume a resource" section, but I did remove it from the above "Configuring quota synchronization period" section, if that was the intention.

For item 1a, I don't see enough information in the linked doc to be able to determine what the right object is to edit, and the right YAML to use instead. Can you help me with the proper steps? 

Thanks!

[1] http://file.rdu.redhat.com/~ahoffer/2019/BZ-1684357/applications/quotas/quotas-setting-per-project.html#quotas-configuring-quota-sync-period-quotas-setting-per-project

Comment 7 Andrea Hoffer 2019-05-17 13:02:10 UTC
Hi @Xingxing Xia, would you be able to take a look at the updates I made for item 2 (See the above comment). The WIP PR is here: https://github.com/openshift/openshift-docs/pull/14639. And just looking for some assistance with the correct steps for item 1a. Thanks!

Comment 8 Xingxing Xia 2019-05-20 10:22:42 UTC
For item 2, https://github.com/openshift/openshift-docs/pull/14639 LGTM
For 1b, maybe somebody did the removal of master-restart.
For 1a, there is Dev change of configuration steps I need to investigate next days.

Comment 9 Xingxing Xia 2019-05-24 10:35:20 UTC
Andrea, as to 1a, today I tried but didn't get a working 4.1 configuring way for "Requiring explicit quota to consume a resource". It is better to consult Pod or Master Dev directly.

Comment 10 Andrea Hoffer 2019-05-24 19:57:08 UTC
Thanks @Xingxing Xia, I'll reach out. I'm going to go ahead and merge this PR so that item 2 is taken care of, and I will follow up with a separate PR for item 1 once we determine the updates needed.

Comment 13 Xingxing Xia 2019-06-05 09:52:24 UTC
Notes for assigning back: comment 12 was done by errata system. But per previous comment 9 - 11, item 1a still needs update for current new Target Release.

Comment 16 Xingxing Xia 2019-06-10 06:39:32 UTC
PR LGTM, thanks

Comment 17 Andrea Hoffer 2019-06-10 12:47:52 UTC
Thanks! Moving to release pending.

Comment 18 errata-xmlrpc 2019-06-19 06:45:34 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/RHBA-2019:1382


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