-
Notifications
You must be signed in to change notification settings - Fork 27
Add option to disable master redirection #72
Comments
Have you tried to set the ip property into your mesos-master configuration? I had the same error and I resolved it by this way. |
Luiz, Oscar |
Payero, The configuration that must be present is "hostname", not "ip". As you can see in the manual (http://mesos.apache.org/documentation/latest/configuration/) there are several configurations for mesos master and slave nodes. If you are starting the master as service all the configs are mapped at /etc/mesos-master/ path just as files. For example: If you want to set the quorum of your mesos-master, you just need to add a file called quorum (with no extensions) at /etc/mesos-master/ and then add an integer to you file (1, 2, 3 ...). Once mesos is starting, the service reads the folder and for each file found, mesos will read its content and transform it into the named configuration of your file. So basically, if I create a file called hostname with content equal to "www.google.com" mesos will start with: --hostname=www.google.com. |
@Payero Thanks for reaching out. The ip address returned by Mesos is the ip it has been configured to bind to for all of its communication, including between the masters and agents of the cluster. The property used to config the ip address mesos will listen on (masters and agents) is In general it's not a great idea to have your mesos master directly accessible for framework registration outside the cluster as this can lead to rogue frameworks taking resources. If you have access to the cluster, using a vpn or using ssh/scp to run your framework inside the cluster will generally be easier from an architecture standpoint. I'd like to leave this issue one, and rename it to "Add option to disable master redirection" if that's okay with you? |
Ben, Oscar |
@Payero Sounds good, and good call turning on auth in mesos itself to protect yourself. |
+1 for this issue =) |
I am not completely familiar with the internals of a Mesos cluster, but I have a question. My settings is simple: 1 AWS EC2 instance running mesos and 1 laptop running the Sleepy framework. When I run the framework the MesosClient probes the endpoint using the EC2 public IP address and returns a new link to the master.
2017-03-31 17:58:59,881 INFO [main ] c.m.mesos.rx.java.MesosClient - Probing Mesos server at http://aws-public-ip:5050/redirect
This probe gets redirected to:
Using new Mesos URI: {} http://aws-private-ip:5050/api/v1/scheduler
Because it gets redirected to the private IP and the laptop is on a different subnet it cannot connect to it. In order to get it to work I added a kludge where I look for a system property and if is set then skip the redirect. This kludge works, but I was wondering if there is a better way to do this.
Thanks
Oscar
The text was updated successfully, but these errors were encountered: