O'Reilly logo

Mastering CentOS 7 Linux Server by Bhaskarjyoti Roy, Mohamed Alibi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Setting up the Clamav antivirus

Clamav is an open source antivirus tool. Its basic usage is for detecting viruses, malware, and malicious software on Linux-based machines.

To install Clamav, we need to install the EPEL repository:

$ sudo yum install epel-release

Then we can install Clamav with all its useful tools:

$ sudo yum install clamav-server clamav-data clamav-update clamav-filesystem clamav clamav-scanner-systemd clamav-devel clamav-lib clamav-server-systemd

Before we start configuring, we need to make sure that SELinux will let Clamav work without issues:

$ sudo setsebool -P antivirus_can_scan_system 1

To check whether the option is active, we need to type this:

$ sudo getseboot –a | grep virus

Then we remove the example configuration, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required