如题,虽然可以在网页端清空回收站中已删除的资料库,但是磁盘里的剩余容量一直没有变化,导致已删除的文件还一直占用的空间。只能手动去本地删除 storage/blocks/ 下对应 ID 的文件夹。
有什么办法可以在网页端,彻底磁盘中删除资料库吗?
如题,虽然可以在网页端清空回收站中已删除的资料库,但是磁盘里的剩余容量一直没有变化,导致已删除的文件还一直占用的空间。只能手动去本地删除 storage/blocks/ 下对应 ID 的文件夹。
有什么办法可以在网页端,彻底磁盘中删除资料库吗?
在论坛或者文档中搜一下 seaf-gc
多谢指点,但是使用以后并没有效果,具体操作及日志如下
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh --dry-run
Starting seafserv-gc, please wait ...
[11/04/16 10:45:42] gc-core.c(440): GC version 1 repo 我的资料库(85d90845-cc79-4131-acbc-e5191ae43176)
[11/04/16 10:45:42] gc-core.c(309): No blocks. Skip GC.
[11/04/16 10:45:42] gc-core.c(440): GC version 1 repo IotCameraU盘(50c638dc-2f07-435d-83a3-382f8338c7a5)
[11/04/16 10:45:42] gc-core.c(313): GC started. Total block number is 5.
[11/04/16 10:45:42] gc-core.c(46): GC index size is 1024 Byte.
[11/04/16 10:45:42] gc-core.c(327): Populating index.
[11/04/16 10:45:42] gc-core.c(181): Populating index for repo 50c638dc.
[11/04/16 10:45:42] gc-core.c(234): Traversed 6 commits, 5 blocks.
[11/04/16 10:45:42] gc-core.c(343): Scanning unused blocks.
[11/04/16 10:45:42] gc-core.c(369): GC finished. 5 blocks total, about 5 reachable blocks, 0 blocks can be removed.
[11/04/16 10:45:42] gc-core.c(440): GC version 1 repo My Library Template(186c7ea5-33d9-4d02-a98c-b844a962681c)
[11/04/16 10:45:42] gc-core.c(309): No blocks. Skip GC.
[11/04/16 10:45:42] gc-core.c(384): === Repos deleted by users ===
[11/04/16 10:45:42] gc-core.c(397): Repo e2818947 can be GC'ed.
[11/04/16 10:45:42] gc-core.c(397): Repo 3109ac05 can be GC'ed.
[11/04/16 10:45:42] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh run
Starting seafserv-gc, please wait ...
[11/04/16 10:45:55] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh verify
Starting seafserv-gc, please wait ...
[11/04/16 10:46:16] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh force
Starting seafserv-gc, please wait ...
[11/04/16 10:46:30] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh verify
Starting seafserv-gc, please wait ...
[11/04/16 10:46:33] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $ ./seaf-gc.sh --dry-run
Starting seafserv-gc, please wait ...
[11/04/16 10:46:42] gc-core.c(440): GC version 1 repo 我的资料库(85d90845-cc79-4131-acbc-e5191ae43176)
[11/04/16 10:46:42] gc-core.c(309): No blocks. Skip GC.
[11/04/16 10:46:42] gc-core.c(440): GC version 1 repo IotCameraU盘(50c638dc-2f07-435d-83a3-382f8338c7a5)
[11/04/16 10:46:42] gc-core.c(313): GC started. Total block number is 5.
[11/04/16 10:46:42] gc-core.c(46): GC index size is 1024 Byte.
[11/04/16 10:46:42] gc-core.c(327): Populating index.
[11/04/16 10:46:42] gc-core.c(181): Populating index for repo 50c638dc.
[11/04/16 10:46:42] gc-core.c(234): Traversed 6 commits, 5 blocks.
[11/04/16 10:46:42] gc-core.c(343): Scanning unused blocks.
[11/04/16 10:46:42] gc-core.c(369): GC finished. 5 blocks total, about 5 reachable blocks, 0 blocks can be removed.
[11/04/16 10:46:42] gc-core.c(440): GC version 1 repo My Library Template(186c7ea5-33d9-4d02-a98c-b844a962681c)
[11/04/16 10:46:42] gc-core.c(309): No blocks. Skip GC.
[11/04/16 10:46:42] gc-core.c(384): === Repos deleted by users ===
[11/04/16 10:46:42] gc-core.c(397): Repo e2818947 can be GC'ed.
[11/04/16 10:46:42] gc-core.c(397): Repo 3109ac05 can be GC'ed.
[11/04/16 10:46:42] gc-core.c(456): === GC is finished ===
seafserv-gc run done
Done.
pi@raspberrypi:~/seafile/seafile-server-latest $
看一下文档中的 删除垃圾数据块 ./seaf-gc.sh -r
搞明白了, 删除第一类无用数据块 指的就是清空回收站后,依然残留的数据。
感觉文档这块描述还不够具体,是不是把章节标题从 删除垃圾数据块 改为 彻底清除已清空回收站后残留数据 会更好?
另外,明明已经清空回收站了,但是服务器已删除的资料库并没有被彻底清除,这样做的意图是什么?为了方便数据还原吗?