Hallo,
* Jean-Marc LACROIX [Fri, Jan 31 2020, 02:29:39PM]:

> Package: apt-cacher-ng
> Version: 3.2-2
> Severity: important
>
> Dear maintainers,
>
> Many thanks for the packaging of this application ().

Just for your information, your mail setup makes it hard to receive your
mails (forged domain flag and similar in the spamfilter).

> Two questions about this application.
>
> After reading  the documentation and many  blogs on Internet, it seems
> not  possible to set  maximum size  to  the parameter : "CacheDir:" in
> configuration file.

What you mean is not the maximum size of the parameter (the string
length) but the maximum size of the cache.

> As a result, of course, after some times, this directory can be full.

Normally, a directory cannot be full. A harddisk can be full.

> Of course it is possible to mount this directory to one dedicated disc
> mount point, but the issue is always the same, it depends of disc size
> (!).

Yes. You can counteract with filesystem quotas, since the daemon
normally runs under aa specific user id.

> My dream   is to  specify  one limit  (!)   in this  parameter,  with
> potential associated   policy (optional) to   manage automatically old
> files when disc is full for example.
>
> Q1: Is it possible ?

Generally speaking: not yet. It is one of the new options which would
become available with the next generation (yeah, -ng-ng :-) ). The plan
is to move the internal metadata handling completely into an embedded
database. That will allow for tracking of used space at runtime without
serious costs on OS/CPU/disk.

But it's not as easy as you probably imagine it. Detecting out-of-space
condition is one thing, resolving the problem is another. It would
require some kind of "on-the-fly cache invalidation" strategy which the
user could specify in the configuration. And it needs to be extra
carefull in order to not destroy the whole cache by mistake.

At the moment, you can partly do something similar (but offline, not
online) with "acngtool shrink ..." command.  Although for a better
trade-off, it requires additional information which has to be collected
at runtime, so for most precise cache invalidation, it needs the
"TrackFileUse=1" option in the acng configuration. And having this set
for some time, so the daemon can collect statistics and then acngtool
knows which files are lest recently used and which ones are just
garbage.

> Q2: Furthermore, it seems that when disc is full, then all clients
> can not download files when launching apt update/upgrade  with following
> error : "Failed to update apt cache", perhaps due to
> [HTTP error, code: 503] in /var/log/apt-cacher-ng/apt-cacher.log ?

Not sure what you mean. Asking whether it looks like this? Probably yes.
Or asking to confirm it? Sorry, you refer to a Stable version.  Stable
is not subject to change (much), I don't have enough time to run after
such issues in a frozen version.

Best regards,
Eduard.

Reply via email to