Server Fault Asked by Felix Hagspiel on December 29, 2021
I got two VMs on Azure that are in the same subnet. One VM (10.1.0.6) has clamav daemon running, the other runs a Java Wildfly Application (10.1.0.5).
I would like to send files from Java Application to the clam av daemon.
I checked that Clamav is running and listening on port 3310:
netstat -ant|grep 3310
tcp 0 0 127.0.0.1:3310 0.0.0.0:* LISTEN
netstat -lnp | grep clam
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
unix 2 [ ACC ] STREAM LISTENING 800631 -
/var/run/clamav/clamd.ctl
For the Clam Av server there are all inbound ports open within the virtual private network. However, if I check on the java server if the port is available via telnet or nc I get:
telnet 10.1.0.6 3310
Trying 10.1.0.6...
telnet: Unable to connect to remote host: Connection refused
nc -vz 10.1.0.6 3310
nc: connect to 10.1.0.6 port 3310 (tcp) failed: Connection refused
If I send files via Java Application I get the same error.
Is my clamav setup correctly and is this issue related to my Subnet configuration?
Thanks for your help!
The problem was that the daemon was listening on the loopback IP address (127.0.0.1). I had to switch this is to listen on 10.1.0.6 (0.0.0.0 should also work).
added in /etc/clamav/clamd.conf
:
TCPSocket 3310
TCPAddr 10.1.0.6
added in /etc/systemd/system/clamav-daemon.service.d/extend.conf
ListenStream=10.1.0.6:3310
Restarted the daemon and now it is working!
Answered by Felix Hagspiel on December 29, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP