Member-only story
Installing ClamAV on ubuntu
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 clamav
and 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…