I think I have resolved this with:
# touch /var/run/clamd.scan/clamd.sock
# chown clamscan: /var/run/clamd.scan/clamd.sock
then uncommented these lines in /etc/clamd.d/scan.conf:
sed -i -- 's/#PidFile \/var\/run\/clamd.scan\/clamd.pid/PidFile \/var\/run\/clamd.scan\/clamd.pid/g' /etc/clamd.d/scan.conf
sed -i -- 's/#LocalSocket \/var\/run\/clamd.scan\/clamd.sock/LocalSocket \/var\/run\/clamd.scan\/clamd.sock/g' /etc/clamd.d/scan.conf
systemctl restart [email protected]
I could test this with:
clamdscan -c /etc/clamd.d/scan.conf /etc/hosts
Give it a few moments try again, if not restart the service, ultimatley a restart may need to be
prior the fix:
ERROR: Could not lookup (null): Servname not supported for ai_socktype
after the fix:
/etc/hosts: OK
I hope it helps.