Summary: | app-antivirus/clamav-0.100.1 systemd: possible duplication of systemd service files | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Dennis Lamm <expeditioneer> |
Component: | Current packages | Assignee: | Antivirus Team <antivirus> |
Status: | CONFIRMED --- | ||
Severity: | normal | CC: | arthur, kangie, lucas.yamanishi, proxy-maint, systemd, wolfram |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Dennis Lamm
2018-07-26 19:08:00 UTC
adding the systemd team to it If someone could have a look and let me know if the upstream files are better/suitable/.. please let me know - if not then I'll try to have a look at some point soon *** Bug 670731 has been marked as a duplicate of this bug. *** (In reply to Thomas Raschbacher from comment #1) > adding the systemd team to it > > If someone could have a look and let me know if the upstream files are > better/suitable/.. please let me know - if not then I'll try to have a look > at some point soon See my comment in my duplicate bug #662196: (In reply to Wolfram Schlich from comment #0) > app-antivirus/clamav-0.100.2 installs 2 systemd units for clamd: > > /lib/systemd/system/clamd.service > /lib/systemd/system/clamav-daemon.service > > clamd.service seems to be the one that should be killed as it forks clamd in > the background (not systemds philosophy) and it's also not related to > clamav-daemon.socket (but clamav-daemon.service is). would appreciate if someone who is familiar with systemd could look into this (see the comment on bug #670731) Yes, there are duplicate service files 2731 root 20 0 10792 3608 3140 R 0.0 0.1 0:03.32 top 2681 clamav 20 0 16040 4136 3196 S 0.0 0.1 0:00.00 freshclam 2716 clamav 20 0 959828 824544 0 S 0.0 21.4 0:00.00 clamd 2722 clamav 20 0 959824 834112 9576 S 0.0 21.7 0:34.90 clamd 2726 clamav 20 0 16148 8420 7444 S 0.0 0.2 0:00.00 freshclam And their service files are -> clamav-daemon.service [Unit] Description=Clam AntiVirus userspace daemon Documentation=man:clamd(8) man:clamd.conf(5) https://www.clamav.net/documents/ Requires=clamav-daemon.socket # Check for database existence ConditionPathExistsGlob=/var/lib/clamav/main.{c[vl]d,inc} ConditionPathExistsGlob=/var/lib/clamav/daily.{c[vl]d,inc} [Service] ExecStart=/usr/sbin/clamd --foreground=true # Reload the database ExecReload=/bin/kill -USR2 $MAINPID StandardOutput=syslog [Install] WantedBy=multi-user.target Also=clamav-daemon.socket -> clamd.service [Unit] Description=clamd scanner daemon After=nss-lookup.target network.target [Service] Type=forking ExecStart=/usr/sbin/clamd Restart=on-failure PrivateTmp=true [Install] WantedBy=multi-user.target And -> clamav-freshclam.service [Unit] Description=ClamAV virus database updater Documentation=man:freshclam(1) man:freshclam.conf(5) https://www.clamav.net/documents # If user wants it run from cron, don't start the daemon. ConditionPathExists=!/etc/cron.d/clamav-freshclam [Service] ExecStart=/usr/bin/freshclam -d --foreground=true StandardOutput=syslog [Install] WantedBy=multi-user.target --> freshclamd.service [Unit] Description=clamav updater [Service] Type=forking User=clamav Group=clamav RuntimeDirectory=clamav PIDFile=/run/clamav/freshclam.pid ExecStart=/usr/bin/freshclam -d -p /run/clamav/freshclam.pid [Install] WantedBy=multi-user.target |