-
Notifications
You must be signed in to change notification settings - Fork 14.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update graceful node shutdown docs for beta #26963
Update graceful node shutdown docs for beta #26963
Conversation
Deploy preview for kubernetes-io-vnext-staging processing. Building with commit b222a13 https://app.netlify.com/sites/kubernetes-io-vnext-staging/deploys/605d33764045290008b53a37 |
/assign @mvortizr |
@bobbypage how do I know if this is working?
Also I can see that the containers get killed by systemd (I have set
This is with version 1.20.4 with this config:
Also tried setting I can see that the inhibitor is registered:
I can open a separate issue if you want to... |
Ok, if I do a This is on Ubuntu 20.04.2 |
Hi @yvespp Good to hear you got it working. systemd inhibitors don't delay the shutdown if you execute |
@bobbypage VMWare seems to have no way to shut down the vm via power button/ACPI events. It either shuts down the vm via vm-tools or basically just pulls the power.
I looks like there are some features in future versions of systemd that might improve the situation:
However I noticed that the pods on the node get deleted but they start immediately again and then get killed by systemd when to os shuts down... This can't be the intention, right? |
@yvespp thanks for trying it out. Do you want maybe open a separate github issue so we can debug further and keep this PR focused on the doc changes? Thanks! |
3924846
to
6617a04
Compare
Updated the PR with update to the docs, this should be ready to review now. |
@kubernetes/sig-node-pr-reviews Can you provide a review? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some feedback. I'd be willing to merge without seeing that addressed, but I'd definitely prefer to have those changes considered.
Kubelet ensures that pods follow the normal [pod termination process](/docs/concepts/workloads/pods/pod-lifecycle/#pod-termination) during the node shutdown. | ||
|
||
When the `GracefulNodeShutdown` feature gate is enabled, kubelet uses [systemd inhibitor locks](https://www.freedesktop.org/wiki/Software/systemd/inhibit/) to delay the node shutdown with a given duration. During a shutdown kubelet terminates pods in two phases: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd still mention that feature gate, but tell readers that it is enabled by default. Not every cluster opts in to every beta feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated with a note regarding feature gate, please take a look.
Note that by default, both `ShutdownGracePeriod` and `ShutdownGracePeriodCriticalPods` are set to zero, thus disabling Graceful Node Shutdown functionality. | ||
To enable the feature, the two kubelet config settings should be configured appropriately and set to non-zero values. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please consider moving this much earlier in the page - it looks important!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, moved this section earlier.
6617a04
to
85f5e0a
Compare
@bobbypage the PR description mentions that it is a:
If this is ready for review, I recommend you reword that so it's clear. |
95b583c
to
1b85439
Compare
Thanks @sftim this is ready for review, I updated the PR description and addressed your comments. |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: tengqm The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |
/lgtm cancel |
@bobbypage Please rebase |
LGTM if rebased the “obvious” way. |
1b85439
to
b222a13
Compare
Rebased, thanks for the review! PTAL again, @sftim @reylejano |
Hi @caesarxuchao @dchen1107 @SergeyKanzhelev @karan @mrunalp @kubernetes/sig-node-pr-reviews , please provide a technical review (tech lgtm) for this PR by March 31 to get this into the release. Thank you! |
I'm happy to LGTM this. We can revert if there's been some kind of grave error here! /lgtm |
LGTM label has been added. Git tree hash: 92cf8c32e8807a45156e2ddf470bae55efed9790
|
/sig node
Enhancement Issue - kubernetes/enhancements#2000
Promotion of graceful node shutdown to beta - kubernetes/kubernetes#99735