Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1328359 - Ansible playbooks crash randomly after upgrading 1.9 --> 2.0.1
Summary: Ansible playbooks crash randomly after upgrading 1.9 --> 2.0.1
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: ansible
Version: 23
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Kevin Fenzi
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-04-19 08:10 UTC by Kees de Jong
Modified: 2016-05-07 14:33 UTC (History)
6 users (show)

Fixed In Version: ansible-2.0.2.0-1.fc22 ansible-2.0.2.0-1.fc23 ansible-2.0.2.0-1.fc24 ansible-2.0.2.0-1.el7 ansible-2.0.2.0-1.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-04-30 00:20:40 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Kees de Jong 2016-04-19 08:10:35 UTC
Description of problem:
Since the upgrade to ansible-2.0.1.0-2.fc23.noarch my playbooks are behaving randomly. For example the copy actions for my bash environment for my own user and root. First it fails for root. Second try, nothing changed, it succeeds. More tasks behave like this which can be considered a critical drop in quality and reliability of Ansible.

TASK [common : copy bash environment for keesj] ********************************
ok: [127.0.0.1] => (item={u'dest': u'.bash_profile', u'src': u'bash_profile'})
ok: [127.0.0.1] => (item={u'dest': u'.bashrc', u'src': u'bashrc'})
ok: [127.0.0.1] => (item={u'dest': u'.bash_aliases', u'src': u'bash_aliases'})
ok: [127.0.0.1] => (item={u'dest': u'.forward', u'src': u'forward'})

TASK [common : copy bash environment for root] *********************************
fatal: [127.0.0.1]: FAILED! => {"failed": true, "msg": "failed to resolve remote temporary directory from ansible-tmp-1461052804.64-126912064857518: `( umask 22 && mkdir -p \"` echo $HOME/.ansible/tmp/ansible-tmp-1461052804.64-126912064857518 `\" && echo \"` echo $HOME/.ansible/tmp/ansible-tmp-1461052804.64-126912064857518 `\" )` returned empty string"}

NO MORE HOSTS LEFT *************************************************************
        to retry, use: --limit @workstation.retry

PLAY RECAP *********************************************************************
127.0.0.1                  : ok=18   changed=0    unreachable=0    failed=1   





[root@defiant Ansible]# ansible-playbook -i workstation_hosts workstation.yml --ask-vault-pass -t copy_bash_keesj,copy_bash_root
Vault password: 

PLAY ***************************************************************************

TASK [setup] *******************************************************************
ok: [127.0.0.1]

TASK [common : copy bash environment for keesj] ********************************
ok: [127.0.0.1] => (item={u'dest': u'.bash_profile', u'src': u'bash_profile'})
ok: [127.0.0.1] => (item={u'dest': u'.bashrc', u'src': u'bashrc'})
ok: [127.0.0.1] => (item={u'dest': u'.bash_aliases', u'src': u'bash_aliases'})
ok: [127.0.0.1] => (item={u'dest': u'.forward', u'src': u'forward'})

TASK [common : copy bash environment for root] *********************************
ok: [127.0.0.1] => (item={u'dest': u'.bash_profile', u'src': u'bash_profile_root'})
ok: [127.0.0.1] => (item={u'dest': u'.bashrc', u'src': u'bashrc_root'})
ok: [127.0.0.1] => (item={u'dest': u'.bash_aliases', u'src': u'bash_aliases_root'})
ok: [127.0.0.1] => (item={u'dest': u'.forward', u'src': u'forward'})

PLAY ***************************************************************************

TASK [setup] *******************************************************************
ok: [127.0.0.1]

PLAY RECAP *********************************************************************
127.0.0.1                  : ok=4    changed=0    unreachable=0    failed=0   


Version-Release number of selected component (if applicable): ansible-2.0.1.0-2.fc23.noarch


How reproducible:
Add this as a task.

- name: copy bash environment for keesj
  copy: src={{ item.src }} dest=/home/keesj/{{ item.dest }} owner=keesj group=keesj mode=644
  with_items:
    - { src: "bash_profile", dest: ".bash_profile" }
    - { src: "bashrc", dest: ".bashrc" }
    - { src: "bash_aliases", dest: ".bash_aliases" }
    - { src: "forward", dest: ".forward" }
  tags: copy_bash_keesj

- name: copy bash environment for root
  copy: src={{ item.src }} dest=/root/{{ item.dest }} owner=root group=root mode=644
  with_items:
    - { src: "bash_profile_root", dest: ".bash_profile" }
    - { src: "bashrc_root", dest: ".bashrc" }
    - { src: "bash_aliases_root", dest: ".bash_aliases" }
    - { src: "forward", dest: ".forward" }
  tags: copy_bash_root

Then run it, sometimes it works, sometimes it doesn't. But I'm not sure it's because of this task, set of files and configurations specific. It's more about this warning that pop-ups randomly in this task and others: fatal: [127.0.0.1]: FAILED! => {"failed": true, "msg": "failed to resolve remote temporary directory from ansible-tmp-1461052804.64-126912064857518: `( umask 22 && mkdir -p \"` echo $HOME/.ansible/tmp/ansible-tmp-1461052804.64-126912064857518 `\" && echo \"` echo $HOME/.ansible/tmp/ansible-tmp-1461052804.64-126912064857518 `\" )` returned empty string"}

Expected results:
A major version update of course can have syntax problems with old configurations. But these results are so random it can't be syntax but rather the quality of Ansible.

Additional info:
I will downgrade, I don't think Ansible 2.0 is ready yet for Fedora.

Comment 1 Kevin Fenzi 2016-04-19 16:12:09 UTC
This is this upstream bug: 
https://github.com/ansible/ansible/issues/13876

Note that it's very sporadic. Some folks see it often, many others don't see it at all. There's a partial fix that should be out in 2.0.2.0 which should be out soon. 

You can remove the 'ansible' package and install 'ansible1.9' if you wish to stay on the 1.9.x releases for now.

Comment 2 Fedora Update System 2016-04-20 00:12:41 UTC
ansible-2.0.2.0-1.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-679c4ddd3c

Comment 3 Fedora Update System 2016-04-20 00:13:11 UTC
ansible-2.0.2.0-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-cd3cf8e7d0

Comment 4 Fedora Update System 2016-04-20 00:13:36 UTC
ansible-2.0.2.0-1.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2016-ab154c56dd

Comment 5 Fedora Update System 2016-04-20 00:13:56 UTC
ansible-2.0.2.0-1.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-56e02a47c7

Comment 6 Fedora Update System 2016-04-20 00:14:14 UTC
ansible-2.0.2.0-1.el6 has been submitted as an update to Fedora EPEL 6. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-09ad0ba4a5

Comment 7 Fedora Update System 2016-04-20 20:22:09 UTC
ansible-2.0.2.0-1.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-679c4ddd3c

Comment 8 Fedora Update System 2016-04-21 21:21:26 UTC
ansible-2.0.2.0-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-cd3cf8e7d0

Comment 9 Fedora Update System 2016-04-22 03:25:17 UTC
ansible-2.0.2.0-1.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-ab154c56dd

Comment 10 Kees de Jong 2016-04-22 13:10:49 UTC
Confirmed, ansible-2.0.2.0-1.fc23 does work as expected, thanks!

Comment 11 Fedora Update System 2016-04-22 20:47:40 UTC
ansible-2.0.2.0-1.el6 has been pushed to the Fedora EPEL 6 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-09ad0ba4a5

Comment 12 Fedora Update System 2016-04-22 20:49:33 UTC
ansible-2.0.2.0-1.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-56e02a47c7

Comment 13 Fedora Update System 2016-04-30 00:20:24 UTC
ansible-2.0.2.0-1.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.

Comment 14 Fedora Update System 2016-04-30 00:24:28 UTC
ansible-2.0.2.0-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 15 Fedora Update System 2016-05-07 12:02:49 UTC
ansible-2.0.2.0-1.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 16 Fedora Update System 2016-05-07 14:05:02 UTC
ansible-2.0.2.0-1.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 17 Fedora Update System 2016-05-07 14:33:28 UTC
ansible-2.0.2.0-1.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.