Document URL: https://access.redhat.com/documentation/en/openshift-enterprise/version-3.1/installation-and-configuration/#post-deployment-configuration Section Number and Name: 17.4. POST-DEPLOYMENT CONFIGURATION Describe the issue: After working with some of the engineers for the EFK stack, it became apparent that when you make changes to any part of the EFK stack (specifically the FluentD or ElasticSearch) you should scale both of these down to zero, make the changes, and then scale them back up to the appropriate numbers, trying to scale FluentD not too long after scaling ElasticSearch. Suggestions for improvement: Make a note about this so that anytime changes are made, the appropriate actions are taken. Additional information: You can do this by running `oc scale --replicas=0 dc/<ELASTICSEARCH_DC> dc/<FLUENTD_DC> ` and then, after you have made the change (like attach a PVC) you can scale them back up using `oc scale --replicas=# dc/<ELASTICSEARCH_DC>` and `oc scale --replicas=# dc/<FLUENTD_DC>`
Hi Eric and Anping, I opened the following PR with a note instructing readers to scale Elasticsearch and Fluentd as recommended: https://github.com/openshift/openshift-docs/pull/7281
Brandi, Fluentd is deployed as daemonset. you couldn't scale down fluentd. The correct way is to make the fluentd don't match any nodes. To scale to zero: +---- +$ oc scale --replicas=0 dc/<ELASTICSEARCH_DC> $ get the fluentd node selector oc get ds logging-fluentd -o yaml |grep -A 1 Selector nodeSelector: logging-infra-fluentd: "true" $ Change nodeSelector in daemonset configure to match zero node +---- + +To scale to back up from zero: +---- +$ oc scale --replicas=# dc/<ELASTICSEARCH_DC> + Change the nodeSelector back in daemonset configure.
You can use oc patch command to modify the daemonset nodeSelector. oc patch ds logging-fluentd -p '{"spec":{"template":{"spec":{"nodeSelector":{"nonexistlabel":"true"}}}}}'
Brandi, How about change as the following? +Change nodeSelector in the daemonset configuration to match zero: +---- $ get the fluentd node selector $ oc get ds logging-fluentd -o yaml |grep -A 1 Selector nodeSelector: logging-infra-fluentd: "true" Use the `oc patch` command to modify the daemonset nodeSelector: oc patch ds logging-fluentd -p '{"spec":{"template":{"spec":{"nodeSelector":{"nonexistlabel":"true"}}}}}' $ get the fluentd node selector $ oc get ds logging-fluentd -o yaml |grep -A 1 Selector nodeSelector: "nonexistlabel: "true" To scale Elastcsearch back up from zero: ---- $ oc scale --replicas=# dc/<ELASTICSEARCH_DC> ---- change nodeSelector in the daemonset configuration to back to logging-infra-fluentd: "true Use the `oc patch` command to modify the daemonset nodeSelector: ---- oc patch ds logging-fluentd -p '{"spec":{"template":{"spec":{"nodeSelector":{"logging-infra-fluentd":"true"}}}}}'
Thanks, Anping! I updated the PR: https://github.com/openshift/openshift-docs/pull/7281
Looks good to me now.
Commits pushed to master at https://github.com/openshift/openshift-docs https://github.com/openshift/openshift-docs/commit/ca24ef03bbd5d32000b35fa52537ec2a8e6ead81 Bug 1314564 Add Instructions to Scale EFK Pods When Changes are Made https://github.com/openshift/openshift-docs/commit/cf6b546a9f96c9bfbce20cc5834eb8e0e2a81314 Merge pull request #7778 from bmcelvee/BZ1314564 Bug 1314564 Add Instructions to Scale EFK Pods When Changes are Made
Link to documentation on the Customer Portal: https://access.redhat.com/documentation/en-us/openshift_enterprise/3.1/html-single/installation_and_configuration/#fluentd