I figured this out, and it prompts me to wonder if there's been a request to propagate boto debug info via ansible yet. If not, is there a clean way this could be included? I had to write a script to debug boto output to get the reason for the failure. Being able to propagate this error up to ansible might be beneficial in the future. Additionally, I'm wondering why so many volumes were left orphaned in our AWS account. I'm not blaming the EC2 module, but I haven't found that cause yet.
We hit a limit in our EBS volumes. For future debugging reference, I'll include my troubleshooting below.
#!/usr/bin/python
import boto
import os
from pprint import pprint
version = boto.Version
print version
boto.set_stream_logger('boto')
conn = boto.connect_ec2(aws_access_key_id=os.environ['AWS_ACCESS_KEY_ID'],aws_secret_access_key=os.environ['AWS_SECRET_ACCESS_KEY'])
res= conn.get_all_reservations()
pprint(res[0].instances)
I ran the ansible-playbook command and took snapshots of the boto output every 15 seconds while it ran, then diff'ed the first and last one:
while true; do echo "running $(date)"; /tmp/test.py &> /tmp/test.py.output.$(date +%s); sleep 15; done
This was the obvious difference:
> <stateReason>
> <code>Client.VolumeLimitExceeded</code>
> <message>Client.VolumeLimitExceeded: Volume limit exceeded</message>
> </stateReason>