apt-get update fails

3,584 views
Skip to first unread message

Tom Gertin

unread,
Apr 1, 2015, 7:57:52 PM4/1/15
to ansible...@googlegroups.com
I am trying to run an 'apt-get update' command in my Ansible playbook but it is failing everytime. 

I am using the 'apt: update_cache=yes' command found here: http://docs.ansible.com/apt_module.html

It returns the following error:

TASK: [update apt cache] ******************************************************
failed: [localhost] => {"failed": true}
msg: Could not fetch updated apt files

FATAL: all hosts have already failed -- aborting


I created an Ubuntu trusty machine using virtualbox and I installed Ansible on it and I am running the scripts on the VirtualBox. My repo, which contains my Ansible scripts is here: https://github.com/d3netxer/ansible-osm-history-set-up

Thanks,

Tom

James Martin

unread,
Apr 3, 2015, 2:30:53 PM4/3/15
to ansible...@googlegroups.com
Do the commands work when run by hand?  Sounds like it could be a connectivity issue.

Matteo Scandolo

unread,
Apr 14, 2015, 7:16:05 AM4/14/15
to ansible...@googlegroups.com
Hi, I'm stucked with the same issue...

The command seems to work when runned by hand, but it exit whit this output:


E: Some index files failed to download. They have been ignored, or old ones used instead.

I think that it can be someway related to this. Am I right?

Thanks in advance
Reply all
Reply to author
Forward
0 new messages