Skip to content

Commit 862e4ac

Browse files
Split tmp directory notes into their own section
1 parent cc2ec93 commit 862e4ac

File tree

1 file changed

+21
-2
lines changed

1 file changed

+21
-2
lines changed

README.md

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,29 @@ If using features that rely on OpenCV (see the [Downsampling type](#downsampling
3333

3434
__NOTE:__ If you are setting `jna.library.path` via the `JAVA_OPTS` environment variable, make sure the path is to the folder __containing__ the library not path to the library itself.
3535

36-
If the default temporary directory (usually `/tmp/`) is mounted as `noexec`, conversion will fail.
37-
The easiest solution is to choose a different temporary directory by adding `-Djava.io.tmpdir=/path/to/alternate/tmp` to `JAVA_OPTS`.
36+
Temporary directory usage
37+
=========================
38+
39+
Beginning with 0.10.0, if the default temporary directory (usually `/tmp/`) is mounted as `noexec`, conversion will fail immediately by default.
40+
[CIS security benchmarks](https://www.cisecurity.org/benchmark) recommend that `/tmp/` be mounted as `noexec`; these standards are increasingly
41+
being adopted by major Linux distributions. For certain types of input data (e.g. NDPI, JPEG-XR compression), bioformats2raw needs
42+
to extract a native library from one or more jars to a temporary location. In these cases, the extracted native library must be executable in order
43+
to read image data.
44+
45+
The recommended solution is to choose a different temporary directory by adding `-Djava.io.tmpdir=/path/to/alternate/tmp` to `JAVA_OPTS`.
3846
If multiple properties need to be set via `JAVA_OPTS`, separate them with a space, e.g. `JAVA_OPTS=-Djava.io.tmpdir/path/to/alternate/tmp -Djna.library.path=/path/to/blosc`.
3947

48+
If you know this issue does not affect your input data and wish to warn instead of immediately stopping conversion, the `--warn-no-exec` option can be used.
49+
For input data that relies on native library loading (e.g. NDPI, JPEG-XR compression), using `--warn-no-exec` instead of specifying an alternate
50+
temporary directory will simply cause the conversion to fail at a later point.
51+
52+
For additional information, please see:
53+
54+
* https://github.com/glencoesoftware/bioformats2raw/pull/252
55+
* https://github.com/scijava/native-lib-loader/issues/41
56+
* https://forum.image.sc/t/after-omero-server-upgrade-hamamatsu-ndpi-files-display-only-in-low-resolution/81868
57+
* https://forum.image.sc/t/bioformats-unable-to-read-czi-files-with-jpegxr-compression-on-almalinux-os-java-lang-unsatisfiedlinkerror-ome-jxrlib-jxrjni-new-decodecontext-j/82646
58+
4059
Installation
4160
============
4261

0 commit comments

Comments
 (0)