Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@haircommander
Copy link
Member

What type of PR is this?

/kind feature

What this PR does / why we need it:

cherry-pick of #3999, #4691, #4697 and #5144

Which issue(s) this PR fixes:

Special notes for your reviewer:

Does this PR introduce a user-facing change?

add clean_shutdown_file option to allow crio/crio wipe to verify crio had time to shutdown cleanly

@openshift-ci openshift-ci bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. kind/feature Categorizes issue or PR as related to a new feature. labels Aug 19, 2021
@openshift-ci openshift-ci bot requested a review from nalind August 19, 2021 20:45
@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 19, 2021
haircommander and others added 4 commits August 19, 2021 16:52
there are cases where crio doesn't get the chance to sync before shutdown.
In these cases, container storage can be corrupted.
We need to protect against this case by wiping all of storage if we detect we didn't cleanly shutdown.

Add an option to specify a clean_shutdown_file that crio will create upon syncing at shutdown
Add an option to crio-wipe to clear all of storage if that file is not present
Add integration tests to verify

Signed-off-by: Peter Hunt <[email protected]>
We created the CleanShutdownFile to work around issues where nodes didn't have time
to sync changes to disk before rebooting. This caused an unclean reboot.

However, for this to be relevant, the node had to actually reboot. If it didn't,
we could fail to remove the storage because the containers are still running.

In this case, we shouldn't wipe anything.

Signed-off-by: Peter Hunt <[email protected]>
or else, we will unconditionally try to remove the whole directory after upgrading from 1.20,
rather than pointedly removing crio specific containers

Signed-off-by: Peter Hunt <[email protected]>
This showed up when I was grepping a journal for `error:`, and it's
not an error.

Signed-off-by: Colin Walters <[email protected]>
@haircommander
Copy link
Member Author

/retest

@mrunalp
Copy link
Member

mrunalp commented Aug 23, 2021

okay, verified that this is what we have in 1.21.

Copy link
Member

@mrunalp mrunalp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Aug 23, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 23, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: haircommander, mrunalp

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [haircommander,mrunalp]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants