MT6 ClamAV

Create a jail for ClamAV
Make a zfs filesystem based off the 'base' snapshot we created:

zfs clone zroot/jails/base@10.0 zroot/jails/clamav

Start up the jail:

service jail start clamav

Mount /usr/ports from the host system and enter the jail:

jail_manage clamav

Install ClamAV:

pkg install clamav echo 'clamav_freshclam_enable="YES"' >> /etc/rc.conf echo 'clamav_clamd_enable="YES"' >> /etc/rc.conf service clamav-freshclam start service clamav-clamd start

The first attempt to start clamd will likely fail, because freshclam hasn't finished downloading 65+MB of databases. Wait a few minutes and try again. You can watch for *.cvd files to appear in /var/db/clamav. Peruse through the options in /usr/local/etc/clamd.conf. At the least, you'll need to update TCPAddr and bind it to the loopback IP:

cd /usr/local/etc sed -i .bak -e 's/#TCPAddr 127.0.0.1/TCPAddr 127.0.0.5/' clamd.conf sed -i .bak -e 's/#TCPSocket 3310/TCPSocket 3310/' clamd.conf sed -i .bak -e 's/#LogFacility LOG_MAIL/LogFacility LOG_MAIL/' clamd.conf sed -i .bak -e 's/#LogSyslog yes/LogSyslog yes/' clamd.conf sed -i .bak -e 's/^LogFile /#LogFile /' clamd.conf

Maybe now freshclam will have finished:

service clamav-clamd start