Hey Federico,
I tried it again this morning and had slightly better luck. The env var
is still not setting the IP properly but the agent did connect after I
manually altered it and restarted the agent service. Not sure why it
connected this time and not before. I have lots of end users and it
would be better if they didn't have to manually edit config files to get
this to connect so I would still like a resolution of that problem if
possible.
I attached the ossec.conf files from both servers in the cluster.
Here are the nmap results:
From agent to server:
# nmap -p 1514,1515 192.168.220.41
PORT STATE SERVICE
1514/tcp open fujitsu-dtcns
1515/tcp open ifor-protocol
from server to agent:
# nmap -p 1514,1515 192.168.222.56
PORT STATE SERVICE
1514/tcp closed fujitsu-dtcns
1515/tcp closed ifor-protocol
Not sure why they show closed from the server to the agent. The
connection succeeded now and the firewall is disable on both machines:
# ufw status
Status: inactive
# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
but I can see that the server VM is listening but the agent VM is not
attempting to listen on those ports:
server listening ports:
# sudo netstat -tulpn | grep .*wazuh.*
tcp 0 0
0.0.0.0:1514 0.0.0.0:*
LISTEN 1940/wazuh-remoted
tcp 0 0
0.0.0.0:1515 0.0.0.0:*
LISTEN 1520/wazuh-authd
agent listening ports:
# netstat -tulpn | grep .*wazuh.*
On 5/19/22 07:15, Federico Pacher wrote:
> Hi there,
>
> Sorry for my late response. Would you mind sharing:
>
> 1- ossec.conf of your managers (master node and workers nodes), in case
> you cannot share these files please share how to configure the
> *<cluster> *tag of your master node and worker nodes, something like this:
> /*
> <cluster>
> <name>wazuh</name>
> <node_name>node02</node_name>
> <node_type>worker</node_type>
> <key>248d7d032ab400e6609308405fd8243f</key>
> <port>1516</port>
> <bind_addr>0.0.0.0</bind_addr>
> <nodes>
> <node>192.168.0.246</node>
> </nodes>
> <hidden>no</hidden>
> <disabled>no</disabled>
> </cluster>*/
>
> 2- the ossec.log file of your agent located in /*/var/ossec/log/ossec.log*/
>
> Please check if your port 1515 and 1514 in your managers and your agents
> are open
> - 1514 Agent connection service
> - 1515 Agent enrollment service
>
> To check this:
>
> Agent side
> # /nmap -p 1515 manager_ip/
> Manager side
> # /nmap -p 1515 agent_ip/
> --
> You received this message because you are subscribed to the Google
> Groups "Wazuh mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
wazuh+un...@googlegroups.com
> <mailto:
wazuh+un...@googlegroups.com>.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/wazuh/a814a8ec-5039-451a-9ba3-f8b9f890ecaen%40googlegroups.com
> <
https://groups.google.com/d/msgid/wazuh/a814a8ec-5039-451a-9ba3-f8b9f890ecaen%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
Edward Sandberg
Adventium Labs
111 3rd Avenue S. Suite #100
Minneapolis, MN 55401
ed.sa...@adventiumlabs.com