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
fix: restore volume mount when VolumeConfigure fails (#7669)
Chris Lu772459f93ca5
diff --git a/weed/server/volume_grpc_admin.go b/weed/server/volume_grpc_admin.goindex 52e0856846..4125f503aa 100644--- a/weed/server/volume_grpc_admin.go+++ b/weed/server/volume_grpc_admin.go@@ -134,6 +134,11 @@ func (vs *VolumeServer) VolumeConfigure(ctx context.Context, req *volume_server_if err := vs.store.ConfigureVolume(needle.VolumeId(req.VolumeId), req.Replication); err != nil {glog.Errorf("volume configure %v: %v", req, err)resp.Error = fmt.Sprintf("volume configure %v: %v", req, err)+ // Try to re-mount to restore the volume state+ if mountErr := vs.store.MountVolume(needle.VolumeId(req.VolumeId)); mountErr != nil {+ glog.Errorf("volume configure failed to restore mount %v: %v", req, mountErr)+ resp.Error += fmt.Sprintf(". Also failed to restore mount: %v", mountErr)+ }return resp, nil}