everpeace / vagrant-mesos

Spin up your Mesos Cluster with Vagrant! (VirtualBox and AWS)
https://github.com/everpeace/vagrant-mesos
MIT License
432 stars 138 forks source link

Marathon and chronos processes are not restarted #58

Open AlexeyKupershtokh opened 9 years ago

AlexeyKupershtokh commented 9 years ago

When you do vagrant up on the multinodes cluster, then do vagrant halt marathon and vagrant up again, neither marathon nor chronos processes are started within the marathon VM. One have to destroy the vm instead and spend more time on vagrant up each time. PS: I don't see anything related to chronos or marathon in the marathon:/etc/init/ or marathon:/etc/init.d/

goodgoblin commented 9 years ago

For what it's worth -- take a look at the Vagrant file.

nohup /opt/marathon/bin/start --master zk://localhost:2181/mesos --zk_hosts localhost:2181 --event_subscriber http_callback > /var/log/marathon/nohup.log 2> /var/log/marathon/nohup.log < /dev/null &

You can use that to start marathon once you ssh into the box.

You can probably also use

vagrant provision

to get it to run again.

everpeace commented 9 years ago

Or you can vagrant up --provision to execute provision phase again. This shouldn't happen mesos master/slave process' restart when mesos related configuration hasn't been changed.

goodgoblin commented 9 years ago

I think he is saying that marathon doesn't restart -- mesos master and slave seem to start fine though.

everpeace commented 9 years ago

@goodgoblin Once vm provisioned, mesos-master/slave process was registered to upstart. So you needn't to worry about. But, marathon process was started bash provisioner in vagrant-mesos as you noticed. So, I wanted to point out that if they wanted start marathon process by vagrant command, they need to vagrant up --provision. However this command also spawns chef provisioner. So they might be worry about happening unnecessary restart of mesos-master/slave processes. I wanted to point point out this thing.

AlexeyKupershtokh commented 9 years ago

Hello guys. Thank you for your help. I'll check these approaches shortly. But Isn't it worth to make marathon and chronos start by the upstart as well?

goodgoblin commented 9 years ago

@everpeace thanks -- that makes sense. @AlexeyKupershtokh adding to upstart would be a fine idea, but it may be tricky b/c of initialization order?

granthbr commented 9 years ago

I'm having an similar issue. Marathon and Chronos don't start. So I try

vagrant provision

The vagrant box restarts then says there is problem with the shares and I need to do

vagrant reload

I do that, then the services do not start again. So, I then i try

nohup /opt/marathon/bin/start --master zk://localhost:2181/mesos --zk_hosts localhost:2181 --event_subscriber http_callback > /var/log/marathon/nohup.log 2> /var/log/marathon/nohup.log < /dev/null &

Which does start the service on the box, but, when I attempt to load any Docker service it never properly loads. Any thoughts?

corecanarias commented 8 years ago

I had the same issue, I wasn't able to provision all boxes, what worked for me was first do vagrant up, confirm that marathon/chronos doesn't start and then provision only that machine:

vagrant provision marathon

granthbr commented 8 years ago

I'll give that a shot. Thanks @corecanarias

granthbr commented 8 years ago

I'll give that a shot. Thanks @corecanarias