clamav-daemon doesn't start after installation
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
clamav (Debian) |
Fix Released
|
Unknown
|
|||
clamav (Ubuntu) |
Fix Released
|
High
|
Christian Ehrhardt | ||
Xenial |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
[Impact]
* Installing clamav the user expects things start to run
* Naturally the daemon can only run after the virus-database is updated
(conditions in systemd service)
* But the freshclam service to update the virus-db is not starting either
since the move to systemd (Regression to old behavior)
[Test Case]
* (enable proposed if needed)
* apt-get install clamav-freshclam
* systemctl status clamav-
* this should show "active" (fixed) and not just "loaded" (broken)
[Regression Potential]
* The fix is fairly straightforward so there shouldn't be a lot. But it
affects postinst and while not changing, it has to move some code there
and might affect something in postinst I missed to think about.
* It worked for adt in Y & X and for my manual tests in LXD containers
fine
[Other Info]
* This is (intentionally) only addressing the regression for now.
Once fixed we think of splitting the part of auto-starting clamav-
daemon later on once the DB is ready
Steps to reproduce:
1. Fresh 16.04 Server installation
2. "sudo apt-get install clamav-daemon clamav-freshclam"
3. ClamAV doesn't start even though it should.
$ systemctl status clamav-daemon
● clamav-
Loaded: loaded (/lib/systemd/
Active: inactive (dead)
Condition: start condition failed at Thu 2016-06-09 11:58:19 EEST; 7min ago
Docs: man:clamd(8)
http://
$ systemctl status clamav-
● clamav-
Loaded: loaded (/lib/systemd/
Active: inactive (dead)
Docs: man:freshclam(1)
http://
Also directory /var/run/clamav/ mentioned in /etc/clamav/
ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: clamav-daemon 0.99+dfsg-1ubuntu1
ProcVersionSign
Uname: Linux 4.4.0-22-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.1
Architecture: amd64
Date: Thu Jun 9 12:00:59 2016
EcryptfsInUse: Yes
InstallationDate: Installed on 2016-06-09 (0 days ago)
InstallationMedia: Ubuntu-Server 16.04 LTS "Xenial Xerus" - Release amd64 (20160420.3)
SourcePackage: clamav
UpgradeStatus: No upgrade log present (probably fresh install)
Changed in clamav (Ubuntu): | |
assignee: | nobody → ChristianEhrhardt (paelzer) |
Changed in clamav (Debian): | |
status: | Unknown → New |
description: | updated |
Changed in clamav (Debian): | |
status: | New → Fix Released |
Thank you for taking the time to report this bug and helping to make Ubuntu better.
Indeed on a quick inspection it looks like both services are not running on install. It looks like for clamav-daemon this is intentional as freshclam has not run yet. However I'd expect the freshclam service to start. After starting it manually, it failed in my environment because no proxy was configured and my lab's firewall requires one. I used "dpkg-reconfigure" to configure a proxy, and the script then started the freshclam daemon automatically. However after it successfully ran, it still did not start clamd, noting that it failed to signal clamd in the logs because it was not running.
I'm not sure what the intended behaviour is. I was unable to check Debian's behaviour quickly because of bug 1590747. This needs following up.
Workaround: if you start clamav-freshclam manually, allow it to finish, then start clamav-daemon manually, I think everything will work from there on as normal.