4

We have Mesosphere DC/OS version 1.7 running on 6 vmware vm's with rhel7 and we would now like to add more agents. We were able to increase from our initial 2 agents(vms) to 6 agents(vms) by running dcos_generate_confg.sh --uninstall from the boot node. We then added the new ip addresses to the agent list in genconf/config.yaml and ran --genconf, --preflight, --deploy, --postflight. This worked however the --uninstall blew away our existing public agent, which we had to go back in and re-install.

Is there another way to add agents without running the --uninstall? Very nervous about what that's doing under the hood. Thank you!

grayzzz
  • 53
  • 5

1 Answers1

7

For my part, I also had trouble understanding how to add a node to a cluster, then I found this link that allowed me to do this:

The Mesosphere guide to getting started with DC/OS: Part 2

Go to the "Adding an internet-facing HAproxy load balancer" chapter.

To summarize what I did and which worked:

  • BootStrap Node:

    sudo vi ~/genconf/config.yaml ## add node slave IP
    
    sudo ./dcos_generate_config.sh --install-prereqs
    
    sudo ./dcos_generate_config.sh --preflight
    

You can ignore errors from the existing agents and masters—DC/OS is just telling you it’s already installed, and you probably don’t want to clobber that installation in-place.

sudo scp -r -i genconf/ssh_key genconf/serve $NEW_NODE_IP:~ ## Copy to the node

  • New node:

    sudo mkdir /opt/dcos_install_tmp
    
    sudo cp -r serve/* /opt/dcos_install_tmp/
    
    cd /opt/dcos_install_tmp/
    chmod +x dcos_install.sh
    
    Agent Private
    
         sudo ./dcos_install.sh slave
    
    Agent Public
    
         sudo ./dcos_install.sh slave_public
    
  • BootStrap node:

    sudo ./dcos_generate_config.sh --postflight
    

I hope that this can help you!

Remy Lebeau
  • 454,445
  • 28
  • 366
  • 620
  • 2
    Thanks Benjamin, that worked great, just what we needed! A couple of notes .. on the `cp server/* /opt/dcos_install_tmp/` step, I had to use `cp -r `, there are a couple of required sub directories that were not picked up. Also, had to `chmod +x dcos_install.sh` and fetch_packages.sh. Just nits. The command above makes a public node. To make a private one use: `sudo ./dcos_install.sh slave`. To make a master node use: `sudo ./dcos_install.sh master`. We'll be trying that next. Thanks again. – grayzzz Aug 05 '16 at 13:44