#5965: Check {{{/dev/pts}}} and {{{/dev/shm}}} requirement on linux
--------------------------+-------------------------------------------------
 Reporter:  tornaria      |       Owner:  mabshoff
     Type:  defect        |      Status:  new     
 Priority:  major         |   Milestone:          
Component:  distribution  |    Keywords:          
--------------------------+-------------------------------------------------
 Sage requires both pseudoterminals (for pexpect) and shared memory (for
 pyprocessing semaphores). On modern linux, those are implemented via
 special filesystem mounts:
  - {{{/dev/pts}}} for pseudoterminals (of type {{{devpts}}})
  - {{{/dev/shm}}} for shared memory (of type {{{tmpfs}}})
 A normal system has those mounts active. However, running sage in a chroot
 fails in weird ways if we neglect to mount those inside the chroot:
  - the first one makes pexpect interfaces to fail, e.g.:
 {{{
 sage: gap(2)
 A workspace appears to have been corrupted... automatically rebuilding
 (this is harmless).
 ---------------------------------------------------------------------------
 TypeError                                 Traceback (most recent call
 last)

 /home/tornaria/.sage/temp/arf/10828/_home_tornaria__sage_init_sage_0.py in
 <module>()

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/interfaces/expect.pyc in __call__(self, x, name)
    1002             return cls(self, x, name=name)
    1003         try:
 -> 1004             return self._coerce_from_special_method(x)
    1005         except TypeError:
    1006             raise

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/interfaces/expect.pyc in _coerce_from_special_method(self,
 x)
    1026             s = '_gp_'
    1027         try:
 -> 1028             return (x.__getattribute__(s))(self)
    1029         except AttributeError:
    1030             return self(x._interface_init_())

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/structure/sage_object.so in
 sage.structure.sage_object.SageObject._gap_
 (sage/structure/sage_object.c:3370)()

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/structure/sage_object.so in
 sage.structure.sage_object.SageObject._interface_
 (sage/structure/sage_object.c:3018)()

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/interfaces/expect.pyc in __call__(self, x, name)
    1000             return x
    1001         if isinstance(x, basestring):
 -> 1002             return cls(self, x, name=name)
    1003         try:
    1004             return self._coerce_from_special_method(x)

 /opt/sage-3.4.1-x86_64-Linux/local/lib/python2.5/site-
 packages/sage/interfaces/expect.pyc in __init__(self, parent, value,
 is_name, name)
    1375             except (TypeError, KeyboardInterrupt, RuntimeError,
 ValueError), x:
    1376                 self._session_number = -1
 -> 1377                 raise TypeError, x
    1378         self._session_number = parent._session_number
    1379

 TypeError: Unable to start gap because the command 'gap -r -b -p -T -o
 9999G /opt/sage-3.4.1-x86_64-Linux/data//extcode/gap/sage.g' failed.
 }}}
  - the second one makes pyprocessing to fail, which can be reproduced by:
 {{{
 sage: import processing, processing.synchronize
 sage:
 processing._processing.SemLock(processing.synchronize.BOUNDED_SEMAPHORE,
 1)
 ---------------------------------------------------------------------------
 OSError                                   Traceback (most recent call
 last)

 /home/tornaria/.sage/temp/arf/10892/_home_tornaria__sage_init_sage_0.py in
 <module>()

 OSError: [Errno 38] Function not implemented
 }}}
 Both failures are detected by doctests. The first one all over the place,
 and the second one by doctests in {{{sage/parallel/multiprocessing.py}}}
 and {{{sage/parallel/decorate.py}}}.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/5965>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of 
Reinventing the Wheel

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to