mirror of
https://github.com/minio/minio.git
synced 2024-12-24 06:05:55 -05:00
ignore io.EOF, io.ErrUnexpectedEOF on xl.meta reads in WalkDir() (#16625)
This commit is contained in:
parent
626a4efaad
commit
37134e42d4
@ -2186,7 +2186,8 @@ func toAPIErrorCode(ctx context.Context, err error) (apiErr APIErrorCode) {
|
|||||||
apiErr = ErrTransitionStorageClassNotFoundError
|
apiErr = ErrTransitionStorageClassNotFoundError
|
||||||
case InvalidObjectState:
|
case InvalidObjectState:
|
||||||
apiErr = ErrInvalidObjectState
|
apiErr = ErrInvalidObjectState
|
||||||
|
case PreConditionFailed:
|
||||||
|
apiErr = ErrPreconditionFailed
|
||||||
case BucketQuotaExceeded:
|
case BucketQuotaExceeded:
|
||||||
apiErr = ErrAdminBucketQuotaExceeded
|
apiErr = ErrAdminBucketQuotaExceeded
|
||||||
case *event.ErrInvalidEventName:
|
case *event.ErrInvalidEventName:
|
||||||
|
@ -324,7 +324,12 @@ func (s *xlStorage) WalkDir(ctx context.Context, opts WalkDirOptions, wr io.Writ
|
|||||||
case isSysErrNotDir(err):
|
case isSysErrNotDir(err):
|
||||||
// skip
|
// skip
|
||||||
default:
|
default:
|
||||||
logger.LogIf(ctx, err)
|
// It is totally possible that xl.meta was overwritten
|
||||||
|
// while being concurrently listed at the same time in
|
||||||
|
// such scenarios the 'xl.meta' might get truncated
|
||||||
|
if !IsErrIgnored(err, io.EOF, io.ErrUnexpectedEOF) {
|
||||||
|
logger.LogIf(ctx, err)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user