Read more

fix clamav freshclam failing database updates

Claus-Theodor Riegg
March 29, 2018Software engineer at makandra GmbH

If freshclam updates are failing even though the update servers are available and you find error messages like the following in the log you may have outdated or wrong data in freshclams data files:

Thu Mar 29 12:49:52 2018 -> ClamAV update process started at Thu Mar 29 12:49:52 2018
Thu Mar 29 12:49:52 2018 -> main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Thu Mar 29 12:49:52 2018 -> WARNING: getpatch: Can't download daily-24428.cdiff from db.local.clamav.net
Thu Mar 29 12:49:52 2018 -> WARNING: getpatch: Can't download daily-24428.cdiff from db.local.clamav.net
Thu Mar 29 12:49:52 2018 -> WARNING: getpatch: Can't download daily-24428.cdiff from db.local.clamav.net
Thu Mar 29 12:49:52 2018 -> WARNING: getpatch: Can't download daily-24428.cdiff from db.local.clamav.net
Thu Mar 29 12:49:52 2018 -> WARNING: getpatch: Can't download daily-24428.cdiff from db.local.clamav.net
Thu Mar 29 12:49:52 2018 -> WARNING: Incremental update failed, trying to download daily.cvd
Thu Mar 29 12:49:52 2018 -> Trying host db.local.clamav.net (62.27.56.14)...
Thu Mar 29 13:01:31 2018 -> Downloading daily.cvd [100%]
Thu Mar 29 13:01:31 2018 -> ERROR: Verification: Can't verify database integrity

Fix

Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

Go to /var/lib/clamav and move the following files to /tmp:

  • daily.cld
  • main.cvd
  • mirrors.dat

Afterwards restart freshclam and check the log if the update is working now. If yes you can delete the files you moved to /tmp.

Posted by Claus-Theodor Riegg to makandra Operations (2018-03-29 13:14)