SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
ensure offset in the index file is positive
Chris Lu9708df47d1be
diff --git a/weed/storage/volume_checking.go b/weed/storage/volume_checking.goindex 048944199b..00e04047fd 100644--- a/weed/storage/volume_checking.go+++ b/weed/storage/volume_checking.go@@ -22,7 +22,7 @@ func CheckAndFixVolumeDataIntegrity(v *Volume, indexFile *os.File) (lastAppendAtreturn 0, nil}healthyIndexSize := indexSize- for i := 1; i <= 10; i++ {+ for i := 1; i <= 10 && indexSize >= int64(i)*NeedleMapEntrySize; i++ {// check and fix last 10 entrieslastAppendAtNs, err = doCheckAndFixVolumeData(v, indexFile, indexSize-int64(i)*NeedleMapEntrySize)if err == io.EOF {