Summary: | app-antivirus/clamav-0.75.1: problems with touch & chmod | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Ioannis Aslanidis (RETIRED) <deathwing00> |
Component: | New packages | Assignee: | Antivirus Team <antivirus> |
Status: | VERIFIED TEST-REQUEST | ||
Severity: | minor | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 58960 |
Description
Ioannis Aslanidis (RETIRED)
2004-08-01 03:59:12 UTC
The problem is with the variable ${FRESHCLAM_LOG}: if [ "${START_FRESHCLAM}" = "yes" ]; then if [ -n "${FRESHCLAM_LOG}" ]; then if [ ! -f "${FRESHCLAM_LOG}" ]; then touch "${FRESHCLAM_LOG}" chown clamav:clamav "${FRESHCLAM_LOG}" fi FRESHCLAM_OPTS="${FRESHCLAM_OPTS} -l ${FRESHCLAM_LOG}" fi ebegin "Starting freshclam" start-stop-daemon --start --quiet \ --exec /usr/bin/freshclam -- ${FRESHCLAM_OPTS} eend $? "Failed to start freshclam" fi My /etc/conf.d/clamd has the following lines: # Config file for /etc/init.d/clamd START_CLAMD=yes CLAMD_OPTS="" CLAMD_LOG="" START_FRESHCLAM=yes FRESHCLAM_OPTS="-d -c 2" FRESHCLAM_LOG="/var/log/clam-update.log" It seems the problem is with the variable ${CLAMD_LOG} instead, as it is empty in my /etc/conf.d/clamd... I advise checking first that the variable is not an empty string... if [ "${START_CLAMD}" = "yes" ]; then if [ -S "/tmp/clamd" ]; then rm -f /tmp/clamd fi if [ -n "$CLAMD_LOG}" -a ! -f "${CLAMD_LOG}" ]; then touch "${CLAMD_LOG}" chown clamav:clamav "${CLAMD_LOG}" CLAMD_OPTS="${CLAMD_OPTS}${CLAMD_LOG}" fi ebegin "Starting clamd" start-stop-daemon --start --quiet \ --exec /usr/sbin/clamd -- ${CLAMD_OPTS} eend $? "Failed to start clamd" fi See bug 58978 for a patch to fix this : http://bugs.gentoo.org/attachment.cgi?id=36697&action=view Thanks that did solve the problem :) Additionally, I'd like to ask you to add the following in the stop script: killall freshclam killall clamd as it seems that stopping the daemon (/etc/init.d/clamd stop) does not terminate those processes. Try doing "/etc/init.d/clamd restart" twice and you'll see what I mean. this is already fixed in the current tree .. please check if it works for you now .. Yes, it does work. Cleaning up |