[clamav-users] clamscan (NOT clamdscan) log file setup in *.conf file?

Dennis Peterson dennispe at inetnw.com
Fri Nov 18 01:02:26 UTC 2016


The clamscan tool is a stand-along utility that runs without clamd being 
installed and and isn't aware of and doesn't use or need any of the clamd or 
clamdscan configurations. It does read the freshclam.conf file to learn where 
the signatures are stored. The command line accepts a rich assortment of 
arguments that will allow it to do a great many things. Using it is frequently 
best done with command aliases and shell scripts.

Using a trace utility when executing it will reveal what it does when it starts. 
In the Red Hat Linux family this can be done by running the following command:

strace clamscan -l /tmp/clamscan.log /path 2>&1 | less

where path is the file or directory you wish to scan. The trace is piped to less 
so you can page through the results. The log is created in /tmp/clamscan.log and 
is owned by the current user. The more clamscan arguments you provide the longer 
will be the strace report and the log. Note too that clamscan runs as the 
current user, so it may not see all you wish nor log where you wish, based on 
file system permissions. It also has to load the entire signature set each time 
it is run.

dp

On 11/16/16 11:07 AM, Fouts, Christopher wrote:
> The docs show the following example when running clamscan (NOT clamdscan)
>
> $ clamscan –r –l scan.txt /some_path
>
> How can I configure the log file in the /etc/clamd.d/scan.conf file for clamscan, not for clamdscan? I see
>
> # Uncomment this option to enable logging.
> # LogFile must be writable for the user running daemon.
> # A full path is required.
> # Default: disabled
> LogFile /var/log/clamav/clamd.scan
>
> …but that references the log file for clamdscan (the daemon). And indeed if I run clamscan I don’t see logs in that file.
>
> Chris
>
> _______________________________________________
> clamav-users mailing list
> clamav-users at lists.clamav.net
> http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-users
>
>
> Help us build a comprehensive ClamAV guide:
> https://github.com/vrtadmin/clamav-faq
>
> http://www.clamav.net/contact.html#ml





More information about the clamav-users mailing list