我知道如何扫描一个目录:
clamscan -r /home
但对于我的生活,我似乎无法得到多个目录工作,我似乎无法谷歌这个简单的问题。
我努力了:
clamscan -r /home /otherdir clamscan -r /home,/otherdir
无济于事。
我究竟做错了什么?
您必须将文件夹/文件的列表放在文本文件中,并使用-f将其传递给clamscan。
例如 :
clamscan -r -z -i --bell --file-list=/home/nav/ClamScanTheseFolders.txt
DIRTOSCAN="/home /var/spool /bin /sbin"; for S in ${DIRTOSCAN}; do clamscan -ri "$S" >> "$LOGFILE"; done
信用: https : //www.howtoforge.com/tutorial/configure-clamav-to-scan-and-notify-virus-and-malware/