Member-only story

Installing ClamAV on ubuntu

Nikhil Nanjappa
2 min readAug 22, 2019

--

In this guide, I will talk about how to install ClamAV tools in Ubuntu. Additionally, how to use those tools to scan for local files/folders or using a node environment.

On Ubuntu (v16.04.6)

Setup

The first step is to install the packages clamavand clamav-daemon.

sudo apt-get install clamav clamav-daemon

The clamav installs other dependencies along with it like clamav-freshclam, clamav-base etc.

Next, you will need to start the clamav-freshclam service by running the following command:

sudo service clamav-freshclam restart
sudo service clamav-freshclam status // to verify

This creates a signature file which is required for the next step.

Note: If clamav-freshclam is started for the first time, creation of the signature file takes about 1–3 mins.

Once the signature file is created, you can then start the clamav-daemon service by running the command:

sudo service clamav-daemon start
sudo service clamav-daemon status // to verify

This step creates the clamd socket file (default location is /var/run/clamav/clamd.ctl). Make sure you verify the status of the clamav-daemon. It should not be showing ‘condition

--

--

Nikhil Nanjappa
Nikhil Nanjappa

Written by Nikhil Nanjappa

Experienced Full-Stack Developer who loves sharing knowledge. Gaming & Music addict. Always grateful and looking for new experiences in life.

Responses (2)