Skip to content

Commit 270a8a0

Browse files
authored
Add pdisk error handler for NoDevice(ENODEV) (#21191) (#21298)
2 parents d5be0df + f6052ad commit 270a8a0

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

ydb/library/pdisk_io/aio.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ enum class EIoResult : i64 {
103103
// for broken disk's error-log: "READ_ERROR: The read data could not be recovered from the media"
104104
NoData = 15, // aka ENODATA: GetEvents
105105
RemoteIOError = 16, // aka EREMOTEIO: GetEvents
106-
NoSpaceLeft = 17 // aka ENOSPC: GetEvents
106+
NoSpaceLeft = 17, // aka ENOSPC: GetEvents
107+
NoDevice = 18, // aka ENODEV: GetEvents
107108
};
108109

109110
struct TAsyncIoOperationResult {

ydb/library/pdisk_io/aio_linux.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,7 @@ class TAsyncIoContextLibaio : public IAsyncIoContext {
231231
case EILSEQ: return EIoResult::InvalidSequence;
232232
case ENODATA: return EIoResult::NoData;
233233
case EREMOTEIO: return EIoResult::RemoteIOError;
234+
case ENODEV: return EIoResult::NoDevice;
234235
default: Y_FAIL_S(PDiskInfo << " unexpected error in " << info << ", error# " << -ret
235236
<< " strerror# " << strerror(-ret));
236237
}

0 commit comments

Comments
 (0)