I was trying to place some juju charms on linux containers and the containers failed to start. To debug the issue I sshed into the node where this happened and tried creating an LXC container manually like
ubuntu@slot13:~$ sudo lxc-create -t ubuntu -n pavan
Checking cache download in /var/cache/lxc/trusty/rootfs-amd64 ...
Installing packages in template: ssh,vim,language-pack-en
Downloading ubuntu trusty minimal ...
I: Retrieving Release
It isn't making any progress at all. Its stuck here for a long long time. After a really long time it says,
ERROR: Unable to fetch GPG key from keyserver
and continues to hang. Finally after 20-30 mins, it gives up like
E: Failed getting release file http://archive.ubuntu.com/ubuntu/dists/trusty/Release
Where are the log files corresponding to lxc-create
command? How can I debug this issue?
EDIT: I figured out how to see the debug logs and hence ran the below command a few times
sudo lxc-create -t ubuntu -n pavan --logfile=test.txt --logpriority=DEBUG
test.txt
contains only this
lxc-create 1414897265.204 ERROR lxc_container - Error: pavan creation was not completed
lxc-create 1414897407.757 ERROR lxc_container - Error: pavan creation was not completed
lxc-create 1414897407.759 WARN lxc_log - lxc_log_init called with log already initialized
But still it hangs and the debug logs aren't offering much help.