-
Notifications
You must be signed in to change notification settings - Fork 109
[7.0.x] Skip disk usage check during pre-flight checks #1758
Conversation
I'm not sure this is headed in the right direction. I would look in the direction of programmatically detecting a filesystem type and excluding them from test explicitly. var stat unix.Stat_t
if err := unix.Stat(path, &stat); err != nil {
return trace.ConvertSystemError(err)
}
if unix.Major(stat.Dev) == 0 && stat.Size == 0 {
// exclude this filesystem from disk-specific tests
} This is not 100% as I could not verify it from official documentation certain but close t |
I might be missing something, but do we know why we're even trying to check disk capacity here? I assume it's not specified in the app.yaml? My expectation would be that we're only trying to test or bubble up errors for volumes that specifically indicate a capacity within the app.yaml, and wouldn't require the effort in trying to filter by various types of volumes, as presumably that's a more complicated issue than just detecting virtual filesystems such as /proc. |
@knisbet @a-palchikov Yes, this is a simple regression that we try to check disk usage where we shouldn't (since it's not specified in the manifest but satellite sets the default and checks it anyway). I discussed it with @bernardjkim yesterday, we're gonna remove setting defaults in satellite. |
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.
@bernardjkim Please fill out testing done before merging to show the scenario that was failing before and that now's passing.
The storage checker did not previously have a default HighWatermark value set. These preflight checks did not specify a HighWatermark value and were not intended to run the disk usage checks. Explicitly specifying 0 HighWatermark will skip disk usage checks.
c4e1d82
to
278a7aa
Compare
Description
This PR fixes a bug that was introduced during changes to the storage check due to satellite setting a default HighWatermark value to the storage checker. Storage checkers with unspecified or 0 HighWatermark value will skip the disk usage check.
Type of change
Linked tickets and other PRs
TODOs
Testing done
Verify successful install of single node cluster with mounted /proc volume