Comment 1 for bug 974584

This is easily and repeatably duplicatable on in my lxc lucid container. The error for the last test (with the multiprocessing SemLock OSError seems the most likely to be a shared root cause to me. Interestingly, the OSError was slightly different for me, with a newer lxc: "OSError: [Errno 38] Function not implemented". I checked the syslog and some random other log files, without really knowing where to look, and saw nothing of interest.

As you'd expect from the traceback, you can repeat this error with a single Python call to the standard library.

>>> from multiprocessing import synchronize
>>> synchronize.Lock()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.6/multiprocessing/synchronize.py", line 117, in __init__
    SemLock.__init__(self, SEMAPHORE, 1, 1)
  File "/usr/lib/python2.6/multiprocessing/synchronize.py", line 49, in __init__
    sl = self._semlock = _multiprocessing.SemLock(kind, value, maxvalue)
OSError: [Errno 38] Function not implemented

38 is ENOSYS

I talked with hallyn and this is an lxc issue. Adding this line to the container's fstab will fix the problem:
none dev/shm tmpfs defaults 0 0

He is updating the ubuntu template with this change.