aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--weed/filesys/wfs.go1
-rw-r--r--weed/mount/weedfs.go1
2 files changed, 2 insertions, 0 deletions
diff --git a/weed/filesys/wfs.go b/weed/filesys/wfs.go
index 7ee9a10ea..2a8ecd235 100644
--- a/weed/filesys/wfs.go
+++ b/weed/filesys/wfs.go
@@ -125,6 +125,7 @@ func NewSeaweedFileSystem(option *Option) *WFS {
})
grace.OnInterrupt(func() {
wfs.metaCache.Shutdown()
+ os.RemoveAll(option.getUniqueCacheDir())
})
wfs.root = &Dir{name: wfs.option.FilerMountRootPath, wfs: wfs, id: 1}
diff --git a/weed/mount/weedfs.go b/weed/mount/weedfs.go
index d3342a8de..11958c39e 100644
--- a/weed/mount/weedfs.go
+++ b/weed/mount/weedfs.go
@@ -99,6 +99,7 @@ func NewSeaweedFileSystem(option *Option) *WFS {
})
grace.OnInterrupt(func() {
wfs.metaCache.Shutdown()
+ os.RemoveAll(option.getUniqueCacheDir())
})
if wfs.option.ConcurrentWriters > 0 {