Can’t open freshclam.log in append mode

33 sec read

:: Error in cronjob

ERROR: Problem with internal logger (UpdateLogFile = /var/log/clamav/freshclam.log). ERROR: Can’t open /var/log/clamav/freshclam.log in append mode (check permissions!).

:: How to fix clamav can’t open /var/log/clamav/freshclam.log in append mode in cPanel server
+ Check permission in log files

ls -lh /var/log/clamav/
-rw-r--r--  1 clam clam    0 Jun 29 03:32 freshclam.log
-rw-r-----  1 clam clam 5.2K Jun 26  2014 freshclam.log-20140629

+ Change Database Owner

vim /usr/local/cpanel/3rdparty/etc/freshclam.conf

# By default when started freshclam drops privileges and switches to the
# "clamav" user. This directive allows you to change the database owner.
# Default: clamav (may depend on installation options)
DatabaseOwner clam

+ Change Clamd User

vim /usr/local/cpanel/3rdparty/etc/clamd.conf

# Run as another user (clamd must be started by root for this option to work)
# Default: don't drop privileges
User clam

:: Ref
+ Google
+ ServerTechNet

How to add NAT iptables…

Learn how to enhance your server's security with Config Server Firewall (CSF), a powerful and free firewall for Linux. This guide will walk you...
Sysadmin.ID
32 sec read

Fix AWStats on WHM/cPanel with…

Discover how to fix AWStats issues on WHM/cPanel with NGINX in just a few easy steps, ensuring accurate web statistics for your server. Follow...
Sysadmin.ID
24 sec read

cPanel : Change Main Domain…

Discover how to easily change the main domain's DocumentRoot in cPanel with our step-by-step guide. Learn to navigate the necessary configurations and restart Apache...
Sysadmin.ID
18 sec read

Leave a Reply

Your email address will not be published. Required fields are marked *