From 3d75c8550c36dcb351f3a7979daab88974d7789d Mon Sep 17 00:00:00 2001 From: Colin Yates Date: Wed, 20 Jun 2018 16:27:17 +0100 Subject: [PATCH 1/2] Add notes about garbage collection Fixes #66 --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index f7bab83..036d614 100644 --- a/README.md +++ b/README.md @@ -126,6 +126,12 @@ docker run -d --name seafile \ If you are one of the early users who use the `launcher` script, you should refer to [upgrade from old format](https://github.com/haiwen/seafile-docker/upgrade_from_old_format.md) document. +### Garbage Collection + +When files are deleted, the blocks comprising those files are marked as unused but not immediately removed. To remove them, Seafile requires a ['garbage collection'](https://manual.seafile.com/maintain/seafile_gc.html) process to be run. + +The required scripts can be found in the `/scripts` folder of the docker container. To perform garbage collection, simply run `docker exec seafile /scripts/gc.sh`. For the community edition, this process will stop the seafile server, but it is a relatively quick process and the seafile server will start automatically once the process has finished. The Professional supports an online garbage collection. + ### Troubleshooting You can run docker commands like "docker logs" or "docker exec" to find errors. From b916db66cddbf370d0677b182e6396736113ffc7 Mon Sep 17 00:00:00 2001 From: Colin Yates Date: Thu, 21 Jun 2018 09:29:19 +0100 Subject: [PATCH 2/2] Updated in response to feedback --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 036d614..cf0ffcb 100644 --- a/README.md +++ b/README.md @@ -128,7 +128,7 @@ If you are one of the early users who use the `launcher` script, you should refe ### Garbage Collection -When files are deleted, the blocks comprising those files are marked as unused but not immediately removed. To remove them, Seafile requires a ['garbage collection'](https://manual.seafile.com/maintain/seafile_gc.html) process to be run. +When files are deleted, the blocks comprising those files are not immediately removed as there may be other files that reference those blocks (due to the magic of deduplication). To remove them, Seafile requires a ['garbage collection'](https://manual.seafile.com/maintain/seafile_gc.html) process to be run, which detects which blocks no longer used and purges them. (NOTE: for technical reasons, the GC process does not guarantee that _every single_ orphan block will be deleted.) The required scripts can be found in the `/scripts` folder of the docker container. To perform garbage collection, simply run `docker exec seafile /scripts/gc.sh`. For the community edition, this process will stop the seafile server, but it is a relatively quick process and the seafile server will start automatically once the process has finished. The Professional supports an online garbage collection.