Rancher HA - Host addition fails

Rancher HA was setup properly beneath an ELB (in AWS) and Rancher UI works well. This setup is backed by RDS (database).

I created a new environment - it worked fine. But, when I add a Host to the environment - It does not work fine.

=> When tried adding host via Rancher - it gets stuck in the stage after provisioning
=> When I tried launching an EC2 in AWS and then tried to pair it up with the Rancher Master - the rancher master does not show up anything in the hosts section.

Had anyone tried the Rancher HA setup? Pls let me know.

Thanks.

Hi Navin,

I also similar problem, but in my case, I created resources (ELB, RDS, rancher master ASG), but, I cannot see ASG instances in ELB, it says instanced failed healthcheck threshold. So, are you using cloud formation or terraform for ELB setting? did you also used ssl or not? since one week I try to solve this issue/

Thanks

Hi Devopsgirl,

I can see that you have issues with getting the rancher master up and running beneath an ELB. That works fine for me. I have issues with adding a host in a Rancher Environment.

For you case - Check whether you do this! When a new machine is brought up, does it run the docker command to start the rancher server pairing with the RDS and advertise its address?

Command will be like this:

docker run -d --restart=unless-stopped -p 8080:8080 -p 9345:9345 rancher/server --db-host YOUR-RDS-HOST --db-port 3306 --db-user RDS-USERNAME --db-pass “RDS-PASS” --db-name RDS-DB-NAME --advertise-address IP-OF-THIS-MACHINE

This command should be run once the EC2 is up and running. You can either pass it in the UserData (but you should know the IP-OF-THIS-MACHINE beforehand. OR, you can call a shell script from UserData - in the shell script you get the IP-OF-THIS-MACHINE and append it to the command and run the command.

Hope this helps.

Hi Navin,

Thank you for your email, now I am able too add host to load balancer but when I look at Rancher HA I am not able to get Ha scripts.

I am using external DB, I can reach Rancher portal with each IP, but I cannot reach with load balancer DNS, or CNAME.

SO, I think HA still not enabled since I am not able to get HA scripts still from Rancher portal.

There must be something related DNS setting maybe. are you able to get HA scipts?

Thanks
Sibel