Rocky_Linux_8
Sponsored Link

Clamav AntiVirus : Install2021/07/30

 
Install Clam AntiVirus to protect your System from Virus.
[1] Install Clamav.
# install from EPEL

[root@dlp ~]#
dnf --enablerepo=epel -y install clamav clamav-update
[root@dlp ~]#
vi /etc/freshclam.conf
# line 8: comment out if it enabled

#
Example
# update pattern files manually

[root@dlp ~]#
freshclam

ClamAV update process started at Thu Jul 29 22:49:40 2021
daily database available for download (remote version: 26247)
Time:    7.8s, ETA:    0.0s [========================>]   54.96MiB/54.96MiB
Testing database: '/var/lib/clamav/tmp.014ab7ae6f/clamav-2575c56d69d12ef9585573ca21bcc7a1.tmp-daily.cvd' ...
Database test passed.
daily.cvd updated (version: 26247, sigs: 1964784, f-level: 90, builder: raynman)
main database available for download (remote version: 61)
Time:   25.9s, ETA:    0.0s [========================>]  160.41MiB/160.41MiB
Testing database: '/var/lib/clamav/tmp.014ab7ae6f/clamav-1596dc4775cd5dd9a9e1913260b4d74f.tmp-main.cvd' ...
Database test passed.
main.cvd updated (version: 61, sigs: 6607162, f-level: 90, builder: sigmgr)
bytecode database available for download (remote version: 333)
Time:    0.3s, ETA:    0.0s [========================>]  286.79KiB/286.79KiB
Testing database: '/var/lib/clamav/tmp.014ab7ae6f/clamav-dd2efdaeb4d0f13ea8159e39f82b28a9.tmp-bytecode.cvd' ...
Database test passed.
bytecode.cvd updated (version: 333, sigs: 92, f-level: 63, builder: awillia2)
[2] Try to scan System.
# scan /home

[root@dlp ~]#
clamscan --infected --remove --recursive /home
----------- SCAN SUMMARY -----------
Known viruses: 8556719
Engine version: 0.103.3
Scanned directories: 23
Scanned files: 33
Infected files: 0
Data scanned: 0.00 MB
Data read: 0.00 MB (ratio 0.00:1)
Time: 19.113 sec (0 m 19 s)
Start Date: 2021:07:29 22:51:21
End Date:   2021:07:29 22:51:40

# download trial virus

[root@dlp ~]#
wget https://www.eicar.org/download/eicar.com
[root@dlp ~]#
clamscan --infected --remove --recursive .

# just detected and removed

/root/eicar.com: Win.Test.EICAR_HDB-1 FOUND
/root/eicar.com: Removed.

----------- SCAN SUMMARY -----------
Known viruses: 8556719
Engine version: 0.103.3
Scanned directories: 2
Scanned files: 10
Infected files: 1
Data scanned: 0.00 MB
Data read: 0.00 MB (ratio 0.00:1)
Time: 17.988 sec (0 m 17 s)
Start Date: 2021:07:29 22:51:59
End Date:   2021:07:29 22:52:17
Matched Content