{"action":"closed","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/13023","labels_url":"https://api.github.com/repos/ansible/ansible/issues/13023/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/13023/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/13023/events","html_url":"https://github.com/ansible/ansible/issues/13023","id":114895050,"number":13023,"title":"v2 performance issues","user":{"login":"andyhky","id":366092,"avatar_url":"https://avatars.githubusercontent.com/u/366092?v=3","gravatar_id":"","url":"https://api.github.com/users/andyhky","html_url":"https://github.com/andyhky","followers_url":"https://api.github.com/users/andyhky/followers","following_url":"https://api.github.com/users/andyhky/following{/other_user}","gists_url":"https://api.github.com/users/andyhky/gists{/gist_id}","starred_url":"https://api.github.com/users/andyhky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andyhky/subscriptions","organizations_url":"https://api.github.com/users/andyhky/orgs","repos_url":"https://api.github.com/users/andyhky/repos","events_url":"https://api.github.com/users/andyhky/events{/privacy}","received_events_url":"https://api.github.com/users/andyhky/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ansible/ansible/labels/bug_report","name":"bug_report","color":"fbca04"},{"url":"https://api.github.com/repos/ansible/ansible/labels/P2","name":"P2","color":"fad8c7"},{"url":"https://api.github.com/repos/ansible/ansible/labels/pending_closure","name":"pending_closure","color":"e11d21"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/ansible/ansible/milestones/5","html_url":"https://github.com/ansible/ansible/milestones/v2","labels_url":"https://api.github.com/repos/ansible/ansible/milestones/5/labels","id":975800,"number":5,"title":"v2","description":null,"creator":{"login":"bcoca","id":836171,"avatar_url":"https://avatars.githubusercontent.com/u/836171?v=3","gravatar_id":"","url":"https://api.github.com/users/bcoca","html_url":"https://github.com/bcoca","followers_url":"https://api.github.com/users/bcoca/followers","following_url":"https://api.github.com/users/bcoca/following{/other_user}","gists_url":"https://api.github.com/users/bcoca/gists{/gist_id}","starred_url":"https://api.github.com/users/bcoca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcoca/subscriptions","organizations_url":"https://api.github.com/users/bcoca/orgs","repos_url":"https://api.github.com/users/bcoca/repos","events_url":"https://api.github.com/users/bcoca/events{/privacy}","received_events_url":"https://api.github.com/users/bcoca/received_events","type":"User","site_admin":false},"open_issues":17,"closed_issues":474,"state":"open","created_at":"2015-02-11T19:43:06Z","updated_at":"2015-11-05T18:43:33Z","due_on":null,"closed_at":null},"comments":11,"created_at":"2015-11-03T19:48:16Z","updated_at":"2015-11-05T18:43:33Z","closed_at":"2015-11-05T18:43:33Z","body":"##### Issue Type:\r\n\r\n  - Bug Report\r\n\r\n##### Ansible Version:\r\n\r\n$ ansible --version\r\nansible 2.0.0 (devel eb8ec73ff3) last updated 2015/11/03 14:30:56 (GMT -400)\r\n  lib/ansible/modules/core: (detached HEAD 22c2789b72) last updated 2015/10/28 23:03:02 (GMT -400)\r\n  lib/ansible/modules/extras: (detached HEAD c685b3d387) last updated 2015/10/28 23:03:10 (GMT -400)\r\n  config file =\r\n  configured module search path = None\r\n\r\n##### Ansible Configuration:\r\n\r\nnone\r\n\r\n##### Environment:\r\n\r\nMac OS X 10.10.4\r\n\r\n##### Summary:\r\n\r\nv1 playbook completes in ~3s.\r\nv2 playbook doesn't complete.\r\n\r\n##### Steps To Reproduce:\r\n\r\nPlaybook here: https://gist.github.com/andyhky/8c5ec9485eb059cf0226 but calling with a --limit which goes down to 100 hosts, e.g., --limit c0001-*compute[0:100] or [0-100] for v1. \r\n\r\nI am passing --forks 100 to ansible-playbook.\r\n\r\nTotal Inventory being passed has a little over 5K hosts across 15 groups, with the nova-compute group at ~400 with the --limit I'm passing.\r\n\r\n##### Expected Results:\r\n\r\nAnsible V1, completes in 3s.\r\n\r\nv1 specifics:\r\n\r\n$ ansible --version\r\nansible 1.8.2\r\n  configured module search path = None\r\n\r\n##### Actual Results:\r\n\r\nIt hangs, seemingly forever. I've let it run up to 58 minutes before giving up.  With ANSIBLE_DEBUG=true it hangs here:\r\n\r\n 15102 1446579807.18443: got a task/handler to work on: TASK: debug msg={{ inventory_hostname }}\r\n 15102 1446579807.18449: running TaskExecutor() for removed/TASK: debug msg={{ inventory_hostname }}\r\n 15102 1446579807.18453: in run()\r\n 15102 1446579807.18500: calling self._execute()\r\n 15102 1446579807.18600: no remote address found for delegated host localhost\r\nusing its name, so success depends on DNS resolution\r\n 15102 1446579807.18921: starting attempt loop\r\n 15102 1446579807.18929: running the handler\r\n 15102 1446579807.18935: handler run complete\r\n 15102 1446579807.18943: attempt loop complete, returning result\r\n 15102 1446579807.18948: _execute() done\r\n 15102 1446579807.18952: dumping result to json\r\n 15102 1446579807.18957: done dumping result, returning\r\n 15102 1446579807.18964: done running TaskExecutor() for removed/TASK: debug msg=removed\r\n 15102 1446579807.18966: sending task result\r\n 15102 1446579807.18972: done sending task result\r\n\r\nWhich I think is somewhere around this part in the code:\r\nhttps://github.com/ansible/ansible/blob/devel/lib/ansible/plugins/strategy/__init__.py#L296-L309\r\n\r\nIf I lower the --forks, the playbook ends up completing, but slowly. "}}