Skip to content

Commit

Permalink
Merge pull request kubernetes#101519 from andyzhangx/automated-cherry…
Browse files Browse the repository at this point in the history
…-pick-of-#101398-upstream-release-1.20

Automated cherry pick of kubernetes#101398: fix: set "host is down" as corrupted mount
  • Loading branch information
k8s-ci-robot authored May 7, 2021
2 parents c28b41d + a37f62b commit 30d205f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion staging/src/k8s.io/mount-utils/mount_helper_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func IsCorruptedMnt(err error) bool {
underlyingError = pe.Err
}

return underlyingError == syscall.ENOTCONN || underlyingError == syscall.ESTALE || underlyingError == syscall.EIO || underlyingError == syscall.EACCES
return underlyingError == syscall.ENOTCONN || underlyingError == syscall.ESTALE || underlyingError == syscall.EIO || underlyingError == syscall.EACCES || underlyingError == syscall.EHOSTDOWN
}

// MountInfo represents a single line in /proc/<pid>/mountinfo.
Expand Down
3 changes: 2 additions & 1 deletion staging/src/k8s.io/mount-utils/mount_helper_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ import (
// ERROR_BAD_NET_NAME = 67
// ERROR_SESSION_CREDENTIAL_CONFLICT = 1219
// ERROR_LOGON_FAILURE = 1326
var errorNoList = [...]int{53, 54, 59, 64, 65, 66, 67, 1219, 1326}
// WSAEHOSTDOWN = 10064
var errorNoList = [...]int{53, 54, 59, 64, 65, 66, 67, 1219, 1326, 10064}

// IsCorruptedMnt return true if err is about corrupted mount point
func IsCorruptedMnt(err error) bool {
Expand Down

0 comments on commit 30d205f

Please sign in to comment.