I've got a lot of messages saying [WARN] master changed to 10.76.102.60. In fact each check lead to this message, even if the mesos leader does not change.
Here is a complete log which keep repeating :
ip, port := m.getLeader() you get the hostname (the value is named ip, but it's an hostname and the port of mesos leader. It's displayed in this line : [INFO] reloading from master
Then you compare this ip with the one from mesos-API
if rip := leaderIP(sj.Leader); rip != ip.
Here is the problem, I've manually make the call messos-consul is making to get the sj object.
There is a leader key but the value associated is an ip not a hostname.
The comparison always fails since you compare an IP with an hostname.
I've tried to launch mesos with --hostname <ip address of the host>, the problem seems to be resolve.
I'm not sure if you can qualified this as a bug, but at least it could be mentioned in the documentation.
Hi,
I've got a lot of messages saying
[WARN] master changed to 10.76.102.60
. In fact each check lead to this message, even if the mesos leader does not change. Here is a complete log which keep repeating :I dive into the code to find the source of those logs and it leads me to https://github.com/CiscoCloud/mesos-consul/blob/master/mesos/mesos.go#L71-L81
ip, port := m.getLeader()
you get the hostname (the value is named ip, but it's an hostname and the port of mesos leader. It's displayed in this line :[INFO] reloading from master
Then you compare this ip with the one from mesos-API
if rip := leaderIP(sj.Leader); rip != ip
. Here is the problem, I've manually make the call messos-consul is making to get thesj
object.There is a leader key but the value associated is an ip not a hostname. The comparison always fails since you compare an IP with an hostname.
I've tried to launch mesos with
--hostname <ip address of the host>
, the problem seems to be resolve.I'm not sure if you can qualified this as a bug, but at least it could be mentioned in the documentation.