The sentinel is active. ClamAV is scanning. freshclam is keeping signatures current. On-access scanning watches the upload directory. The nightly scan covers the rest of the filesystem. AIDE monitors for unauthorized changes. A threat that slips past the firewall hits four detection layers before it can cause damage.
1
ClamAV has two scanning modes: clamscan (loads database fresh each run) and clamdscan (submits to running clamd). Use clamdscan for repeated or automated scans.
2
freshclam must run continuously (or on a schedule) or your signatures become stale. Outdated signatures = missed threats.
3
Use the EICAR test string to verify ClamAV is working. Never use real malware samples on production systems.
4
Exit codes: 0 = clean, 1 = infected found, 2 = error. Always check exit codes in scripts -- do not rely on parsing text output.
5
On-access scanning uses fanotify + clamonacc. Scope it carefully -- monitoring the entire filesystem on a busy server has significant performance cost.
6
Quarantine is better than delete. Preserved samples enable forensic analysis. False positives can be recovered. Compliance frameworks often require evidence retention.
7
ClamAV does not detect rootkits. Use rkhunter for rootkit detection and AIDE for file integrity monitoring as complementary layers.
8
Exclude virtual filesystems (/proc, /sys, /dev) from all scans. Scanning these causes errors, wastes time, and finds nothing useful.