Installare CLAMAV su CentOS
Per installare ClamAV antivirus su CentOS 6.0 con updates automatici fai così:
1. Cambia la tua SRC install directory:
# cd /usr/src
2. Esegui il download del pacchetto di installazione di ClamAV, ClamAV database, ClamAV development libraries e ClamAV daemon per il tuo tipo di sistema operativo (32 bit of 64 bit):
Per 32 bit:
# wget http://pkgs.repoforge.org/clamav/clamav-0.97.1-1.el6.rf.i686.rpmhttp://pkgs.repoforge.org/clamav/clamav-db-0.97.1-1.el6.rf.i686.rpm http://pkgs.repoforge.org/clamav/clamav-devel-0.97.1-1.el6.rf.i686.rpmhttp://pkgs.repoforge.org/clamav/clamd-0.97.1-1.el6.rf.i686.rpm
Per 64 bit:
# wget http://pkgs.repoforge.org/clamav/clamav-0.97.1-1.el6.rf.x86_64.rpmhttp://pkgs.repoforge.org/clamav/clamav-db-0.97.1-1.el6.rf.x86_64.rpmhttp://pkgs.repoforge.org/clamav/clamav-devel-0.97.1-1.el6.rf.x86_64.rpmhttp://pkgs.repoforge.org/clamav/clamd-0.97.1-1.el6.rf.x86_64.rpm
3. Installa ClamAV
# rpm -Uvh clam*
4. Fai partire Freshclam per scaricare gli aggiornamenti:
# /usr/bin/freshclam -v 5
Configura gli update automatici di ClamAV:
# touch /var/log/freshclam.log
# chmod 600 /var/log/freshclam.log
# chown clamav /var/log/freshclam.log
6. Aggiungi uno a crontab gli update schedulati:
# nano -w /etc/crontab
Aggiungi alla fine della linea di crontab:
3 * * * * /usr/bin/freshclam --quiet
Poi premi CTRL+X e batti: Y e poi Enter.
7. Crea uno scan schedulato di tipo daily:
# nano -w /etc/cron.daily/clamav-scan
Scrivi questo nel file:
/usr/bin/freshclam /usr/bin/clamscan -ri /
Poi premi CTRL+X poi premi Y e quindi Enter.
Fai il file eseguibile:
# chmod +x /etc/cron.weekly/clamav-scan
E’ tutto.
Eugenio