You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
the number of bytes left in the file is less than nbyte ( in case of this issue )
the read() request was interrupted by a signal ( but this is handled by erlang itself so we can ignore )
the file is a pipe or FIFO or special file and has fewer than nbyte bytes immediately available for reading ( as we handle only regular files so we can ignore )
From these things,
we can regard unexpected_len_and_eof as a sign of close to EOF and
also judge there is no more files if # of bytes returned is less than the AVS header size (128).
so in this case we can stop compaction|diagnose and reduce subsequent file:pread(s) and outputs to error.log as shown above.
yosukehara
changed the title
[leo_object_storage] compaction|diagnose may get slow down when a garbage exist at the end of a avs
[data-compaction][leo_object_storage] compaction|diagnose may get slow down when a garbage exist at the end of a avs
Feb 27, 2018
because file:pread always fail if the size of a invalid key|data is gt; the size of a avs file like this.
In order to avoid this, need to get the size of a avs beforehand and skip pread if the size of a key|data is gt; its file size.
The text was updated successfully, but these errors were encountered: