Skip to content

salt minion failover #28875

Closed
Closed

Description

@chjohnst

I am using the new version in the salt repo for RHEL7 and I am seeing some weird behavior. When using a configuration with "str" for a hot-hot setup, if both of my masters are up when the minion is started it will connect to both of them no problem and they respond to test.ping commands. When I shutdown one of the masters, the minion will still respond to test.ping commands. However, if one of my masters is down in the list on minion start up the minion will fail to completely come up. Is anyone aware of this issue?

The second problem I am running into, if I setup my minion for "failover" if the first master in my list is down the minion will not attempt to connect to the next one (even with the master_alive_interval set to 10s). It will continue trying to connect to the downed master over and over again. If I bring the downed master up, it will connect with an issue, but then if I shut the master down it never actually fails over to the second one in the list.

Does failover work correctly with salt 2014.8.1-1?

Activity

  1. chjohnst commented on Nov 13, 2015

    @chjohnst
    ContributorAuthor

    Also seeing this on one of my masters

    2015-11-13 15:54:34,696 [salt.config ][ERROR ][52503] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...
    ^
    2015-11-13 15:54:34,697 [salt.config ][ERROR ][52494] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...
    ^
    2015-11-13 15:54:34,704 [salt.config ][ERROR ][52497] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...
    ^
    2015-11-13 15:54:34,712 [salt.config ][ERROR ][52490] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...
    ^
    2015-11-13 15:55:34,141 [salt.config ][ERROR ][52484] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...
    ^
    2015-11-13 15:56:34,403 [salt.config ][ERROR ][52484] Error parsing configuration file: /etc/salt/minion.d/_schedule.conf - could not determine a constructor for the tag 'tag:yaml.org,2002:python/object:tornado.concurrent.Future'
    in "", line 7, column 15:
    master: !!python/object:tornado.concurre ...

    2015-11-13 16:02:48,682 [salt.transport.zeromq][ERROR ][53963] Bad load from minion
    2015-11-13 16:02:53,684 [salt.transport.zeromq][ERROR ][53956] Bad load from minion
    2015-11-13 16:02:58,682 [salt.transport.zeromq][ERROR ][53966] Bad load from minion

  2. chjohnst commented on Nov 14, 2015

    @chjohnst
    ContributorAuthor

    Backported to the 5.5-1 version and seeing similar behavior. Seems you need to have the first master in the list up in order for things to work.

    For eg if I have the following in my configuration, if the first host salqa1 is down, the minion will just loop until I bring it up. Shouldn't the minion detect that it is down, then attempt the next one in the list? Is there a setting I am missing somewhere where it attempts X times then jumps to the next?

    master:

    • saltqa1
    • saltqa2

    random_master: True
    master_type: failover
    master_alive_interval: 10
    retry_dns:0

  3. added
    needs-more-info
    on Nov 17, 2015
  4. modified the milestones: Approved, Blocked on Nov 17, 2015
  5. jfindlay commented on Nov 17, 2015

    @jfindlay
    Contributor

    @chjohnst, thanks for the report. What do you mean by 'hot-hot setup', 'one of my masters is down in the list on minion start', and 'setup my minion for "failover"'? Do you mean that you're setting up multiple masters in a failover configuration?

  6. chjohnst commented on Nov 17, 2015

    @chjohnst
    ContributorAuthor

    For my minions I am piloting both settings for my POC of 'failover' and 'str'. If both of my syndics are up and running the minion will connect without an issue to the first one in the list. If I shutdown the syndic/master processes on the first syndic, my minion will failover to the redundant node without any issues. But if the first syndic is down my minion it just hangs trying to connect to and loops (7 times I believe) until I eventually gave up waiting, as my thoughts here are the minion should detect pretty quickly that it cannot get to it and then just failover. From what I am seeing in my experiments here it seems like you need to have the first syndic up in the list in order for the minion to carry on. I am not sure if this is the expected behavior? I have to look through the code a bit more but wanted to make sure this is expected behavior.

    I have test this on the 2015.5.5-1 and the latest 2015.8 version (which has other weird issues I noted earlier in the ticket).

  7. modified the milestones: Approved, Blocked on Nov 17, 2015
  8. added
    bug
    severity-medium
    P2
    and removed
    needs-more-info
    on Nov 17, 2015
  9. jfindlay commented on Nov 17, 2015

    @jfindlay
    Contributor

    @chjohnst, thanks for the extra information. There are some known issues with multimaster, such as #27152, #24243. #18751 may also be related.

  10. Ch3LL commented on Nov 18, 2015

    @Ch3LL
    Contributor

    @chjohnst This has been fixed for str multi-master setup at this PR: #28302 This will be included with 2015.8.2 and should be released soon.

  11. Ch3LL commented on Nov 18, 2015

    @Ch3LL
    Contributor

    @chjohnst I will keep this ticket open for the failover scenario you described above, because the PR does not fix multi-master failover. But for str multi-master this is fixed. Can you please verify this is the case for you and update this ticket once 2015.8.2 is release.

  12. chjohnst commented on Nov 22, 2015

    @chjohnst
    ContributorAuthor

    Ok, unfortunately the 'str' mode seems less than ideal. For every syndic a minion is attached to it, the master will see two responses, ie test.ping or even highstate runs. I can test this out on 2015.8.2 when it is released, but the ideal scenario is utilizing failover mode of course.

  13. Ch3LL commented on Nov 23, 2015

    @Ch3LL
    Contributor

    @chjohnst yeah that makes sense. thanks for the updated response. We have the failover on the radar with this ticket and the other tickets jfindlay referenced. Thanks

  14. added
    Core
    on Sep 19, 2016
  15. stale commented on Jul 1, 2018

    @stale

    This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

    If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    CoreMulti-MasterP2Salt-Syndicbugseverity-mediumstale

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions