aboutsummaryrefslogtreecommitdiff
path: root/weed/storage/volume_loading.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2017-01-06 10:22:20 -0800
committerChris Lu <chris.lu@gmail.com>2017-01-06 10:22:20 -0800
commit13e7069eb9cd72f94e72acb8fbbc9dd0307da703 (patch)
treea093cbe0df8c2d06ea335e616bb5246f9c45ea04 /weed/storage/volume_loading.go
parent54dd925283f443b09db77717c86eea5bf0f9d740 (diff)
downloadseaweedfs-13e7069eb9cd72f94e72acb8fbbc9dd0307da703.tar.xz
seaweedfs-13e7069eb9cd72f94e72acb8fbbc9dd0307da703.zip
keep track of total data file size
Diffstat (limited to 'weed/storage/volume_loading.go')
-rw-r--r--weed/storage/volume_loading.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/weed/storage/volume_loading.go b/weed/storage/volume_loading.go
index f2099de83..7bc65a4a3 100644
--- a/weed/storage/volume_loading.go
+++ b/weed/storage/volume_loading.go
@@ -64,7 +64,7 @@ func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind
return fmt.Errorf("cannot write Volume Index %s.idx: %v", fileName, e)
}
}
- if e = CheckVolumeDataIntegrity(v, indexFile); e != nil {
+ if v.dataFileSize, e = CheckVolumeDataIntegrity(v, indexFile); e != nil {
v.readOnly = true
glog.V(0).Infof("volumeDataIntegrityChecking failed %v", e)
}
@@ -86,6 +86,7 @@ func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind
}
}
}
+
return e
}