[Pkg-clamav-devel] --foreground in /lib/systemd/service/clamav-daemon.service deliberately?

'Sebastian Andrzej Siewior' sebastian at breakpoint.cc
Sat Apr 14 11:03:39 BST 2018


On 2018-04-14 11:44:18 [+0200], Paul Guijt wrote:
> The problem is I asked a question, and I expected an answer. 
> 
> I see two possible options:
> 
> 1. Forking clamd is not good. Foreground as a command line and config file option will be removed. 
> 
> 2. Forking clamd is ok, or no problem. The choice is to the user through the command line or config file. The --foreground=true=  in the systemd service will be removed. 
> 
> Doing nothing here seems bad coding to me. But I'm not a developer, so I just asked. 

I'm sorry, I don't understand.
clamd is supposed to be a daemon which runs in the background. What we
do is to let run clamd run foreground and let systemd fork it. So
systemd can capture its output, monitor it and if needed restart.

If you don't want to run clamd in background then just don't start it
and use clamscan instead. However it will need to load the whole
database each time you invoke that binary for a scan so it might need
some seconds before it actually does anything. You could use clamdscan
instead but this would require that a daemon runs in the background (and
does this costly init once).

I am not aware that the "--foreground=true=" option will be removed. If
so, can you point me to the decoumentation saying so?

> Met vriendelijke groet,
> Paul Guijt 

Sebastian



More information about the Pkg-clamav-devel mailing list