diff options
| author | Chris Lu <chris.lu@gmail.com> | 2019-09-11 09:45:09 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2019-09-11 09:45:09 -0700 |
| commit | 5e9c65469ecf3356fa02b1cef246d83abdb02d14 (patch) | |
| tree | 5995eca154a90445c8a410e4eccb36bb96eb8337 | |
| parent | 02710f96244903bb99fc6376531159d18735afdc (diff) | |
| download | seaweedfs-5e9c65469ecf3356fa02b1cef246d83abdb02d14.tar.xz seaweedfs-5e9c65469ecf3356fa02b1cef246d83abdb02d14.zip | |
volume: skip readonly checking when Destroy()
fix https://github.com/chrislusf/seaweedfs/issues/1063
| -rw-r--r-- | weed/storage/volume_read_write.go | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/weed/storage/volume_read_write.go b/weed/storage/volume_read_write.go index ae05331a4..c0b1ca933 100644 --- a/weed/storage/volume_read_write.go +++ b/weed/storage/volume_read_write.go @@ -40,10 +40,6 @@ func (v *Volume) isFileUnchanged(n *needle.Needle) bool { // Destroy removes everything related to this volume func (v *Volume) Destroy() (err error) { - if v.readOnly { - err = fmt.Errorf("%s is read-only", v.dataFile.Name()) - return - } if v.isCompacting { err = fmt.Errorf("volume %d is compacting", v.Id) return |
