Reboot to Linux and Discover Freedom

Install Virus Protection for Linux

virus-fi

Reasons I use anti-virus on my Linux machines

  • to protect a Windows virtual machine from within the virtual machine
  • to scan files I’m going to send to other people (non-linux PCs)
  • to scan received e-mail that I am going to forward to other people

Clam AntiVirus (ClamAV) is a free, cross-platform antivirus software tool-kit able to detect many types of malicious software, including viruses. One of its main uses is on mail servers as a server-side email virus scanner. My Linux machine may be less likely to be infected, but it’s an enormous stretch to say that I’m invulnerable.


Install ClamAV

You can install ClamAV with the following command:

sudo pacman -S clamav

How to correctly set up ClamAV in Arch, Manjaro and Antergos

Prepare configuration files:

sudo cp /etc/clamav/clamd.conf.sample /etc/clamav/clamd.conf
sudo cp /etc/clamav/freshclam.conf.sample /etc/clamav/freshclam.conf

Edit 2 configuration files:

Note replace gedit with your preferred text editor

sudo gedit /etc/clamav/clamd.conf

Replace the contents of the clamd.conf file with this text
then…

sudo gedit /etc/clamav/freshclam.conf

Replace the contents of the freshclam.conf file with this text


Fix clamd.sock error:

sudo touch /var/lib/clamav/clamd.sock
sudo chown clamav:clamav /var/lib/clamav/clamd.sock

then update the database:

sudo freshclam -v

Finally setup the daemons:

sudo freshclam -d
sudo systemctl enable clamd && sudo systemctl enable freshclamd
sudo systemctl start clamd && sudo systemctl start freshclamd

Check everything is working correctly:

sudo systemctl status clamd && sudo systemctl status freshclamd

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: