Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions omero/sysadmins/troubleshooting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -456,6 +456,48 @@ To resolve this, define the :envvar:`OMERO_TMPDIR` environment variable
to point at a temporary directory located on the local file system
(e.g. :file:`/tmp/omero`).


tmp directory mounted with noexec permissions
---------------------------------------------

Security best practices like the CIS benchmarks or the NIST SP 800-53 framework recommend to
set the `noexec` mount option on the :file:`/tmp` partition. In such systems, Java Native Interface (JNI)
will be unable to make use of the default temporary directory to call native shared libraries which
is a requirement for reading some file formats like NDPI.

Under such situation, errors like the following will appear either server-side or client-side
during import::

java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.NativeLong
at com.sun.jna.ptr.NativeLongByReference.<init>(NativeLongByReference.java:19)

or::

java.lang.UnsatisfiedLinkError: 'void org.libjpegturbo.turbojpeg.TJDecompressor.init()'
at org.libjpegturbo.turbojpeg.TJDecompressor.init(Native Method)

The recommended resolution is to upgrade OMERO.server to version 5.6.17 or later and OMERO.py
to version 5.21.3 or later. Starting with these versions, the Java processes are configured to
use a temporary directory other than :file:`/tmp`.

For older versions of OMERO.server and OMERO.py, a workaround is to set the `java.io.tmpdir`
system property to point at a temporary directory with the appropriate permissions.

For OMERO.server 5.6.16 and below, this aim should be achieved using :property:`omero.jvmcfg.append`::

mkdir -p /opt/omero/OMERO.current/var/tmp
omero config set -- omero.jvmcfg.append -Djava.io.tmpdir=/opt/omero/OMERO.current/var/tmp

For imports using OMERO.py 5.21.2 and earlier, this property should be set using the
:envvar:`JAVA_OPTS` environment variable::

export JAVA_OPTS="-Djava.io.tmpdir=/opt/omero/OMERO.current/var/tmp/"
omero import ...

.. seealso::

https://github.com/ome/openmicroscopy/issues/6439

Other issues
------------

Expand Down