Fix Zimbra High CPU Usage by ClamAV or FreshClam

When a Zimbra server suddenly slows down, administrators often see clamd or freshclam near the top of top and assume the antivirus service is stuck. That can happen, but the two processes do different work: freshclam downloads and verifies signature updates, while clamd scans files and messages. A busy mail queue, a database reload, a failed update loop, or a second antivirus daemon can all look like “ClamAV using too much CPU.” Identify which process is hot before restarting anything or changing antivirus settings.

This guide walks from low risk checks to service recovery. Commands and paths below reflect common Zimbra installations; the exact bundled ClamAV path and supported recovery steps vary by Zimbra Collaboration version. Confirm them against your installed release before making changes.

1. Confirm which ClamAV process is consuming CPU

Start by recording the process name, CPU use, elapsed time, and command path. Run this as root or with an account allowed to inspect system processes:

ps -eo pid,pcpu,pmem,etime,args | grep -E 'clamd|freshclam'

Then watch the suspected process for at least a short interval with top -p PID, replacing PID with the number from the first command. A single reading is not enough to diagnose a sustained problem: ps reports a snapshot, while top helps you see whether CPU use remains high or falls after a scan or update finishes. Also note whether the path belongs to Zimbra, commonly under /opt/zimbra, or to a separate operating-system package.

Linux terminal prompt showing a process-list command filtered for clamd and freshclam
A terminal command filters the process list so you can identify whether clamd or freshclam is active.

If freshclam spikes briefly and exits or returns to idle after a successful update, that is different from a process that stays busy. If clamd is the sustained consumer, message scanning or database loading is a more likely starting point. Do not kill either process just because one sample is high; first check the logs and whether mail is still flowing.

2. Read the antivirus logs before changing settings

Zimbra’s log reference lists antivirus logs under its log directory. On many installations, inspect the recent entries with:

tail -n 80 /opt/zimbra/log/clamd.log
tail -n 80 /opt/zimbra/log/freshclam.log

Look at timestamps alongside the CPU spike. In clamd.log, repeated scan requests or database-load messages can connect the CPU use to mail activity or a signature reload. In freshclam.log, a completed update followed by a quiet period suggests routine update work; repeated connection failures, retries, checksum errors, or an update that never completes call for closer investigation. Check the Zimbra mail log around the same time as well, because a surge in incoming messages or attachment traffic can increase scans.

Linux terminal showing commands to review the recent clamd and freshclam log entries
Use the two log commands to compare scanner activity with signature update activity.

Use Zimbra’s log file reference to confirm the log locations for your release. ClamAV’s FreshClam troubleshooting guide explains common updater errors, including DNS, download, and rate-limit problems. A warning that an engine is older than ClamAV’s latest upstream release does not by itself prove a corrupt database; Zimbra packages a tested engine with a ZCS release.

3. Check for a duplicate updater, low disk space, or a workload surge

Before tuning anything, rule out common causes that can keep the service busy:

  • Duplicate processes: Check for more than one clamd or freshclam process. A separately installed OS-level ClamAV service or a custom cron job may be starting a second copy alongside Zimbra’s managed service. Do not disable a service until you confirm which product owns it and what starts it.
  • Disk pressure: Check available space and inodes with df -h /opt/zimbra and df -i /opt/zimbra. A full filesystem can prevent temporary update or log writes and cause retries. Do not remove signature files by hand to make space.
  • Mail volume: Compare the CPU spike with incoming message volume, attachment size, queued mail, and any recent bulk delivery. A scan-heavy burst can raise clamd use even when the service is healthy.
  • Update connectivity: If freshclam keeps failing, verify the host’s DNS resolution, clock, outbound connectivity, and any required proxy settings. Correct the underlying network or proxy problem instead of repeatedly starting manual update jobs.
Linux terminal prompt with commands to check Zimbra filesystem space and inspect the ClamAV database directory
Check free space and the signature database directory before attempting database recovery.

ClamAV documents how FreshClam’s configuration controls update behavior and logging in its configuration manual. Zimbra also documents a virus-definition update frequency attribute, but its value and configuration should be checked for your own ZCS version. Do not reduce update frequency as a quick CPU fix: stale signatures weaken protection, while a bad DNS or proxy path will continue to fail regardless of the schedule.

4. Apply the least disruptive fix that matches the evidence

If clamd is busy during a mail burst

Let the current work drain while monitoring CPU and mail delivery. If the same pattern recurs, correlate it with message size, compressed attachments, and inbound volume, then review server capacity and your organization’s attachment-scanning policy. Avoid adding undocumented ClamAV limits or excluding file types without assessing the security impact and checking which controls Zimbra supports in the installed release.

If freshclam repeatedly fails

Fix DNS, proxy, firewall, clock, or outbound network access indicated by the log. Ensure only Zimbra’s intended updater is running. Do not schedule frequent manual invocations or download signature databases with ad hoc scripts; ClamAV identifies FreshClam or cvdupdate as supported update methods, and Zimbra’s packaged integration should remain the source of truth for a Zimbra server.

If the database appears damaged or clamd will not start

Errors such as a malformed database, checksum failure, or failed database load need a version-aware recovery. Zimbra’s ClamAV definition reset procedure has different instructions for different ZCS generations, including different FreshClam binary paths. Read the full procedure for the exact version you run before moving or rebuilding any database files. Keep a copy of the existing database until recovery is confirmed, and never apply commands from an old release guide blindly.

Do not replace Zimbra’s ClamAV binaries with a standalone upstream build as a first-line performance fix. Zimbra’s documentation warns that out-of-cycle engine changes may be unsupported; use the appropriate ZCS patch or upgrade path if the bundled engine itself needs updating.

Restart the antivirus service only after checking the cause

If the service remains stuck after the underlying issue is corrected, a controlled antivirus restart may clear a stale process or reload the repaired database. Schedule it when a brief interruption to scanning is acceptable, and follow the command sequence for your ZCS release. The Zimbra procedure documents zmantivirusctl stop and zmantivirusctl start, run as the zimbra user:

su - zimbra
zmantivirusctl stop
zmantivirusctl start
zmcontrol status

Do not use a full zmcontrol stop for a ClamAV-only issue unless your maintenance plan requires it. If the antivirus service fails to return to running, preserve the relevant logs and use Zimbra’s release-specific troubleshooting or support channel rather than looping restarts.

Terminal prompt as the zimbra user showing antivirus stop and start commands followed by a Zimbra status check
The documented antivirus service commands and status check appear at a zimbra user prompt.

5. Verify that CPU use and mail scanning have returned to normal

After the correction or restart, repeat the process check and watch the CPU trend rather than relying on one instantaneous value. Confirm that clamd is present, freshclam is not trapped in repeated retries, and zmcontrol status reports antivirus as running. Review new log entries for successful database loading and the absence of recurring update or scan errors. Finally, verify that normal test messages are delivered and handled according to your organization’s mail-security policy.

A good recovery has three observable signs: the responsible process no longer consumes sustained CPU after its work completes; the logs stop repeating the same error; and Zimbra’s mail flow and antivirus service status remain healthy. If CPU stays high, collect a timestamped process snapshot, the matching clamd.log, freshclam.log, mail-log entries, disk-space results, and your ZCS version. That evidence helps distinguish a real scanner defect from heavy mail volume or a broken update path without weakening malware scanning as a guess.

Version note: Guidance checked October 6, 2026. Zimbra’s Tech Center includes both current references and older, release-specific troubleshooting pages; verify commands and paths against the documentation for your installed ZCS release.

Leave a Comment

7 Best WSUS Tools for Update Management and Troubleshooting

7 Best WSUS Tools for Update Management and Troubleshooting

Compare seven tools that support or complement WSUS, from Microsoft’s native console and diagnostics to third-party patch publishing and remote deployment.

Best Windows System Monitoring Tools: 6 Picks for Server Visibility

Best Windows System Monitoring Tools: 6 Picks for Server Visibility

Compare six Windows system monitoring tools for server health, application visibility, and alerting, with current notes on deployment and licensing.

7 Wake-on-LAN Tools: What’s Still Available From the 2021 List

7 Wake-on-LAN Tools: What’s Still Available From the 2021 List

Compare seven Wake-on-LAN tools by features and availability, including free utilities, network-admin suites, and 2021 picks that have since been retired.

9 Best Ping Tools for Testing Latency and Scanning a Network

9 Best Ping Tools for Testing Latency and Scanning a Network

Compare nine ping tools for quick reachability checks, subnet discovery, TCP tests, and latency monitoring, with guidance on which one fits your network task.

Best TFTP Servers for Windows, Linux, and macOS

Best TFTP Servers for Windows, Linux, and macOS

Compare the best TFTP servers for Windows, Linux, and macOS, including SolarWinds, Tftpd64, tftpd-hpa, atftpd, haneWIN, and dnsmasq.

5 Best Microsoft Access Alternatives for Desktop and Web Databases

5 Best Microsoft Access Alternatives for Desktop and Web Databases

Compare five Microsoft Access alternatives for desktop, SQLite, no-code, and browser-based database work, with strengths, limits, and best-fit use cases.

Open-Source vs. Closed-Source Monitoring Tools Compared

Open-Source vs. Closed-Source Monitoring Tools Compared

Compare open-source and closed-source monitoring tools by cost, support, customization, security, and current options including Zabbix, Nagios, PRTG, and more.

Ingress vs. Egress: What’s the Difference in Networking?

Ingress vs. Egress: What’s the Difference in Networking?

Understand how ingress and egress describe incoming and outgoing traffic, why direction depends on the network boundary, and how to monitor bandwidth and spot risky data transfers.

6 Best Free Syslog Servers to Try for Centralized Logging

6 Best Free Syslog Servers to Try for Centralized Logging

Compare six free syslog servers and collectors for Windows and Linux, including GUI tools, open-source options, search, alerting, and secure transport.

What Is IIS? Microsoft’s Windows Web Server and Alternatives

What Is IIS? Microsoft’s Windows Web Server and Alternatives

See what Microsoft IIS does, how its request pipeline and application pools work, and when Apache, NGINX, or Caddy may fit your web server needs better.