container-create fails with ContainerException: Docker internal Error: ('Connection aborted.', gaierror(-2, 'Name or service not known'))

Bug #1496110 reported by Ryan Rossiter
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Magnum
Fix Released
Undecided
Unassigned

Bug Description

To reproduce:

Follow steps as detailed here: http://docs.openstack.org/developer/magnum/dev/dev-quickstart.html#building-and-using-a-swarm-bay

During the container-create step, the following stacktrace is thrown:

2015-09-15 19:26:23.227 ERROR oslo_messaging.rpc.dispatcher [req-598b04ec-9791-42fe-8781-19ddadc9be21 admin admin] Exception during message handling: Docker internal Error: ('Connection aborted.', gaierror(-2, 'Name or service not known'))
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher Traceback (most recent call last):
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher executor_callback))
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher executor_callback)
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 129, in _do_dispatch
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher result = func(ctxt, **new_args)
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher File "/opt/stack/magnum/magnum/conductor/handlers/docker_conductor.py", line 71, in wrapped
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher "Docker internal Error: %s" % str(e))
2015-09-15 19:26:23.227 TRACE oslo_messaging.rpc.dispatcher ContainerException: Docker internal Error: ('Connection aborted.', gaierror(-2, 'Name or service not known'))

It looks like the problem is here: https://github.com/openstack/magnum/blob/master/magnum/conductor/handlers/docker_conductor.py#L127-L128

docker_utils.parse_docker_image() is expecting an image url:version string is given to it. When following the docs above, the image string given is 'cirros'. This is then parsed to have the image_repo to be 'cirros', which is then given to docker.pull(), where it cannot resolve the url 'cirros', and throws the error above.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to magnum (master)

Reviewed: https://review.openstack.org/223815
Committed: https://git.openstack.org/cgit/openstack/magnum/commit/?id=cf2470b7c9486299493af4c6fac11fb6046a385c
Submitter: Jenkins
Branch: master

commit cf2470b7c9486299493af4c6fac11fb6046a385c
Author: Ryan Rossiter <email address hidden>
Date: Tue Sep 15 21:07:41 2015 +0000

    Change swarm_manager to swarm_master

    When swarm bays are being created, the bay api address is not being set.
    This is because in the template definition, the api_address attribute is
    being set on the swarm_manager, not the swarm_master.

    Change-Id: I19c99db02086c19f76f33bce5ff4f2336b244d7b
    Closes-Bug: #1496110

Changed in magnum:
status: New → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to magnum (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/224315

Adrian Otto (aotto)
Changed in magnum:
milestone: none → mitaka-1
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on magnum (master)

Change abandoned by Adrian Otto (<email address hidden>) on branch: master
Review: https://review.openstack.org/224315
Reason: I am marking this as abandoned so that reviewers are only looking at patches that should be considered for merge. You are welcome to un-abandon this and resubmit a new patch set if you'd like. We would welcome that.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.