You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@mesos.apache.org by Giulio Eulisse <Gi...@cern.ch> on 2015/05/21 15:03:43 UTC

Running mesos-execute inside docker.

Hi,

I've a problem which can be reduced to running:

	> mesos-execute --name="foo" --command="uname -a && hostname" 
--master=leader.mesos:5050

inside a docker container. If I run without `--net=host`, it blocks 
completely (I guess the master / slave cannot communicate back to the 
framework), if I run with `--net=host` everything is fine but I get:

	May 21 14:59:13 cmsbuild30 mesos-slave[1514]: I0521 14:59:13.115659  
1546 slave.cpp:1533] Asked to shut down framework 
	20150418-223037-3834547840-5050-6-2757 by master@128.142.142.228:5050
	May 21 14:59:13 cmsbuild30 mesos-slave[1514]: W0521 14:59:13.117231  
1546 slave.cpp:1548] Cannot shut down unknown framework 
20150418-223037-3834547840-5050-6-2757

in my host machine logs, which is not ideal. Any idea on how to do this 
correctly?

The actual problem I'm trying to solve is using the mesos plugin for a 
jenkins instance which runs inside docker.

-- 
Ciao
Giulio

Re: Running mesos-execute inside docker.

Posted by Tim Chen <ti...@mesosphere.io>.
Hi Giulio,

Can you share your exact docker commands to start the mesos slave and
master?

Thanks!

Tim

On Thu, May 21, 2015 at 12:17 PM, Giulio Eulisse <Gi...@cern.ch>
wrote:

> Mmm, no this does not seem to work. The message is still there. Any other
> suggestions?
>
> --
> Ciao,
> Giulio
>
> On 21 May 2015, at 17:43, Tyson Norris wrote:
>
>  You might try adding --pid=host - I found that running a docker based
>> executor when running slave as a docker container also, I had to do this so
>> the the pids are visible between containers.
>>
>> Tyson
>>
>> On May 21, 2015, at 6:04 AM, Giulio Eulisse <Giulio.Eulisse@cern.ch
>> <ma...@cern.ch>> wrote:
>>
>>
>> Hi,
>>
>> I've a problem which can be reduced to running:
>>
>>  mesos-execute --name="foo" --command="uname -a && hostname"
>>> --master=leader.mesos:5050
>>>
>>
>>
>> inside a docker container. If I run without --net=host, it blocks
>> completely (I guess the master / slave cannot communicate back to the
>> framework), if I run with --net=host everything is fine but I get:
>>
>> May 21 14:59:13 cmsbuild30 mesos-slave[1514]: I0521 14:59:13.115659  1546
>> slave.cpp:1533] Asked to shut down framework
>>  20150418-223037-3834547840-5050-6-2757 by master@128.142.142.228<mailto:
>> master@128.142.142.228>:5050
>> May 21 14:59:13 cmsbuild30 mesos-slave[1514]: W0521 14:59:13.117231  1546
>> slave.cpp:1548] Cannot shut down unknown framework
>> 20150418-223037-3834547840-5050-6-2757
>>
>>
>> in my host machine logs, which is not ideal. Any idea on how to do this
>> correctly?
>>
>> The actual problem I'm trying to solve is using the mesos plugin for a
>> jenkins instance which runs inside docker.
>>
>> --
>> Ciao
>> Giulio
>>
>

Re: Running mesos-execute inside docker.

Posted by Giulio Eulisse <Gi...@cern.ch>.
Mmm, no this does not seem to work. The message is still there. Any 
other suggestions?

-- 
Ciao,
Giulio

On 21 May 2015, at 17:43, Tyson Norris wrote:

> You might try adding --pid=host - I found that running a docker based 
> executor when running slave as a docker container also, I had to do 
> this so the the pids are visible between containers.
>
> Tyson
>
> On May 21, 2015, at 6:04 AM, Giulio Eulisse 
> <Gi...@cern.ch>> wrote:
>
>
> Hi,
>
> I've a problem which can be reduced to running:
>
>> mesos-execute --name="foo" --command="uname -a && hostname" 
>> --master=leader.mesos:5050
>
>
> inside a docker container. If I run without --net=host, it blocks 
> completely (I guess the master / slave cannot communicate back to the 
> framework), if I run with --net=host everything is fine but I get:
>
> May 21 14:59:13 cmsbuild30 mesos-slave[1514]: I0521 14:59:13.115659  
> 1546 slave.cpp:1533] Asked to shut down framework     
> 20150418-223037-3834547840-5050-6-2757 by 
> master@128.142.142.228<ma...@128.142.142.228>:5050
> May 21 14:59:13 cmsbuild30 mesos-slave[1514]: W0521 14:59:13.117231  
> 1546 slave.cpp:1548] Cannot shut down unknown framework 
> 20150418-223037-3834547840-5050-6-2757
>
>
> in my host machine logs, which is not ideal. Any idea on how to do 
> this correctly?
>
> The actual problem I'm trying to solve is using the mesos plugin for a 
> jenkins instance which runs inside docker.
>
> --
> Ciao
> Giulio

Re: Running mesos-execute inside docker.

Posted by Tyson Norris <tn...@adobe.com>.
You might try adding --pid=host - I found that running a docker based executor when running slave as a docker container also, I had to do this so the the pids are visible between containers.

Tyson

On May 21, 2015, at 6:04 AM, Giulio Eulisse <Gi...@cern.ch>> wrote:


Hi,

I've a problem which can be reduced to running:

> mesos-execute --name="foo" --command="uname -a && hostname" --master=leader.mesos:5050


inside a docker container. If I run without --net=host, it blocks completely (I guess the master / slave cannot communicate back to the framework), if I run with --net=host everything is fine but I get:

May 21 14:59:13 cmsbuild30 mesos-slave[1514]: I0521 14:59:13.115659  1546 slave.cpp:1533] Asked to shut down framework     20150418-223037-3834547840-5050-6-2757 by master@128.142.142.228<ma...@128.142.142.228>:5050
May 21 14:59:13 cmsbuild30 mesos-slave[1514]: W0521 14:59:13.117231  1546 slave.cpp:1548] Cannot shut down unknown framework 20150418-223037-3834547840-5050-6-2757


in my host machine logs, which is not ideal. Any idea on how to do this correctly?

The actual problem I'm trying to solve is using the mesos plugin for a jenkins instance which runs inside docker.

--
Ciao
Giulio