[lxc-users] Write operation to /sys/bus/rbd/add fails inside docker container

Christopher Armstrong chris at opdemand.com
Thu Oct 9 17:20:22 UTC 2014


Hi folks,

I've been working with Ceph and Docker containers, and wanted to post a
reply to Omar Marquez's post to the list from October 2013 regarding issues
using Ceph's `rbd map` command within a Linux container:
https://lists.linuxcontainers.org/pipermail/lxc-users/2013-October/005795.html

I filed a bug with Ceph to track this (http://tracker.ceph.com/issues/9355),
but eventually figured out it was because the container didn't have the
same network context as the host does.

I got this working by running the container with both `--net host` and `-v
/sys:/sys`, so that the container can both have the necessary network
context and mount the /sys filesystem as read-write to actually create the
rbd bus.

I know the original post in this list is old, but there seem to be many
people who were struggling to accomplish this, so I wanted to share my
workaround.


*Chris Armstrong*Head of Services
OpDemand / Deis.io

GitHub: https://github.com/deis/deis -- Docs: http://docs.deis.io/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20141009/11f658a8/attachment.html>


More information about the lxc-users mailing list