[Clamav-devel] ClamAV(R) blog: ClamAV 0.102.0 Release Candidate is now available

Micah Snyder (micasnyd) micasnyd at cisco.com
Fri Oct 4 12:13:04 EDT 2019


That's related to something I'd suggested earlier.  I think it would be nice to fork into the background and accept clamdscan connections (but to block scanning) during the initial database load.  Of course, a part of why I like that idea is so that we don't have to put sleep()'s in some of our test harness code.  I suppose it's a bit of a poor excuse to make functional changes to make testing easier.  Others expressed concern that it shouldn't background or accept connections until everything is up.  

We could certainly check if the socket is available first just to fail early if needed, but not bind to it or accept connections until after the database is loaded.  

-Micah

On 10/4/19, 11:40 AM, "clamav-devel on behalf of G.W. Haywood" <clamav-devel-bounces at lists.clamav.net on behalf of clamav-devel at jubileegroup.co.uk> wrote:

    Hi there,
    
    This came about today when I accidentally started a clamd with the
    configuration file of a clamd instance which was already running:
    
    Oct  4 16:16:24 mail6 clamd[13669]: Received 0 file descriptor(s) from systemd.
    Oct  4 16:16:24 mail6 clamd[13669]: clamd daemon 0.101.4 (OS: linux-gnu, ARCH: x86_64, CPU: x86_64)
    Oct  4 16:16:24 mail6 clamd[13669]: Running as user clamav (UID 111, GID 117)
    Oct  4 16:16:24 mail6 clamd[13669]: Log file size limited to 4294967295 bytes.
    Oct  4 16:16:24 mail6 clamd[13669]: Reading databases from /etc/mail/clamav
    Oct  4 16:16:24 mail6 clamd[13669]: Bytecode: Security mode set to "TrustSigned".
    Oct  4 16:21:07 mail6 clamd[13669]: Loaded 8760999 signatures.
    Oct  4 16:21:09 mail6 clamd[13669]: TCP: Cannot bind to [127.0.0.1]:3313: Address already in use
    Oct  4 16:21:09 mail6 clamd[13990]: Not listening on any interfaces
    
    Note that clamd loaded all its databases, which took over four minutes,
    and only then decided that it couldn't listen on any interfaces!
    
    Perhaps it would be better to check for things which can be checked
    quickly *before* loading nine million signatures.
    
    --
    
    73,
    Ged.
    _______________________________________________
    
    clamav-devel mailing list
    clamav-devel at lists.clamav.net
    https://lists.clamav.net/mailman/listinfo/clamav-devel
    
    Please submit your patches to our Bugzilla: http://bugzilla.clamav.net
    
    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-devel mailing list