Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rolling Update Batch Size #15954

Closed
Nagendra86 opened this issue May 21, 2016 · 4 comments
Closed

Rolling Update Batch Size #15954

Nagendra86 opened this issue May 21, 2016 · 4 comments
Labels
bug This issue/PR relates to a bug.

Comments

@Nagendra86
Copy link

Nagendra86 commented May 21, 2016

ISSUE TYPE
  • Bug Report
ANSIBLE VERSION
<!--- Paste verbatim output from “ansible 2.0.1.0” between quotes -->
CONFIGURATION
OS / ENVIRONMENT

CentOS Linux release 7.1.1503

SUMMARY

If One uses : Serial clause in playbook ,it should move to other hosts if it fails for one host ,which i didn't find true.It get failed if my task get failed and doesn't move down to next host

STEPS TO REPRODUCE

pasted below the playbook,which will run on two hosts

<!--- Paste example playbooks or commands between quotes

- name: serial execution on my two hosts db,web
  hosts: webserver
  serial: 1

  tasks:
    - name: This is to execute on single host
      action: copy src=inventory dest=/tmp

 -->
...
EXPECTED RESULTS

when i ran above playbook,which should run on another host as well ,as per the documentation

http://docs.ansible.com/ansible/playbooks_delegation.html

Rolling Update Batch Size

but it fails and exit out ,if it gets failed for first host

ACTUAL RESULTS
<!--- Paste verbatim command output between quotes -->
@WolverineFan
Copy link

We have seen the same issue in Ansible 2.1.0.0 with batch size of 15. If one host in a batch fails, the playbook will exit after that batch rather than the old behavior of continuing until all batches are complete.

@WolverineFan
Copy link

This is still broken in 2.1.1.0

@jimi-c
Copy link
Member

jimi-c commented Aug 18, 2016

@Nagendra86 this is an incorrect assumption about the docs. With serial: 1 but no max_fail_percentage set, the failure of a single host will cause the play to stop executing.

@WolverineFan I am looking into your comments, as I do see the batches ending incorrectly right now.

@jimi-c
Copy link
Member

jimi-c commented Aug 19, 2016

Closing This Ticket

Hi!

We believe the above commit should resolve this problem for you. This will also be included in the next release.

If you continue seeing any problems related to this issue, or if you have any further questions, please let us know by stopping by one of the two mailing lists, as appropriate:

Because this project is very active, we're unlikely to see comments made on closed tickets, but the mailing list is a great way to ask questions, or post if you don't think this particular issue is resolved.

Thank you!

jimi-c added a commit that referenced this issue Aug 25, 2016
The calculation for max_fail_percentage was moved into the linear
strategy a while back, and works better there in the stategy layer
rather than at the PBE layer. This patch removes it from the PBE layer
and tweaks the logic controlling whether or not the next batch is run.

Fixes #15954

(cherry picked from commit 890e096)
sereinity pushed a commit to sereinity-forks/ansible that referenced this issue Jan 25, 2017
The calculation for max_fail_percentage was moved into the linear
strategy a while back, and works better there in the stategy layer
rather than at the PBE layer. This patch removes it from the PBE layer
and tweaks the logic controlling whether or not the next batch is run.

Fixes ansible#15954
@ansibot ansibot added bug This issue/PR relates to a bug. and removed bug_report labels Mar 7, 2018
@ansible ansible locked and limited conversation to collaborators Apr 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug This issue/PR relates to a bug.
Projects
None yet
Development

No branches or pull requests

5 participants