Hi,
I want to call BackGeocoding operator in the mundialis’ s1tbx docker (mundialis/esa-snap:s1tbx) embedding Snap 8.0, but it fails (it runs smoothly with the docker embedding snap7).
I first reported the error in the Mundialis Github (https://github.com/mundialis/esa-snap/issues/8).
According to Markus Neteler from Mundialis, the problem may come from Snap 8 or a related library, that’s why I’m here !
The Mundialis docker is based on latest Alpine Linux image.
If I run the following commands with any Sentinel-1 SLC product…
tBurstIndex=1 -t output.dim S1A_IW_SLC__1SDV_20190103T170041_20190103T170108_025
316_02CD10_2226.zip
INFO: org.esa.snap.core.gpf.operators.tooladapter.ToolAdapterIO: Initializing external tool adapters
INFO: org.esa.snap.core.util.EngineVersionCheckActivator: Please check regularly for new updates for the best SNAP experience.
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.esa.s1tbx.io.sentinel1.Sentinel1Level1Directory: Less than 8K RAM. Using FileCacheImageInputStream
INFO: org.hsqldb.persist.Logger: dataFileCache open start
Executing operator...
20%....30%....40%....50%....60%....70%....80%....90%.... done.
INFO: org.esa.snap.core.gpf.common.WriteOp: Start writing product S1A_IW_SLC__1SDV_20190103T170041_20190103T170108_025316_02CD10_2226 to output.dim
Writing...
..12%..22%.....38%36%34%.....50%....60%....70%....80%....90%.... done.
INFO: org.esa.snap.core.gpf.common.WriteOp: End writing product output to output.dim
INFO: org.esa.snap.core.gpf.common.WriteOp: Time: 1.832 s total, 1.220 ms per line, 0.000053 ms per pixel
# /usr/local/snap/bin/gpt -x -J-Xmx9000m Back-Geocoding output.dim
INFO: org.esa.snap.core.gpf.operators.tooladapter.ToolAdapterIO: Initializing external tool adapters
INFO: org.esa.snap.core.util.EngineVersionCheckActivator: Please check regularly for new updates for the best SNAP experience.
INFO: org.hsqldb.persist.Logger: dataFileCache open start
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x0000000000002076, pid=216, tid=0x00007f3bca8feb20
#
# JRE version: OpenJDK Runtime Environment (8.0_232-b09) (build 1.8.0_232-b09)
# Java VM: OpenJDK 64-Bit Server VM (25.232-b09 mixed mode linux-amd64 compressed oops)
# Derivative: IcedTea 3.14.0
# Distribution: Custom build (Tue Mar 3 13:24:22 UTC 2020)
# Problematic frame:
# C 0x0000000000002076
#
# Core dump written. Default location: /data/core or core.216
#
# An error report file with more information is saved as:
# /data/hs_err_pid216.log
#
# If you would like to submit a bug report, please include
# instructions on how to reproduce the bug and visit:
# https://icedtea.classpath.org/bugzilla
#
Aborted (core dumped)
This is a quite complicated subject… the official baseline (i.e. the one where we ESA test and ensure things are working) are standard operating systems (i.e. those with full glibc and system libraries) with the provided JVM (JRE).
When we start moving outside of this, things start to get more complicated and we can’t ensure they will work and usually we can’t dedicate resources to troubleshooting the approach.
Do you really need an alpine based container? I know people have put together Fedora and Ubuntu based ones…
Maybe you want to reach out to me via direct message and we can try to understand how we can best support you.
We switched to Alpine since the docker image size is a fraction of one based on Ubuntu. It works well (we use it in production) except for the issue indicated above.
I can check if we can additionally also offer (again) an Ubuntu based docker image.
I have reinstated our Ubuntu based docker image with a few updates (PR https://github.com/mundialis/esa-snap/pull/10). Once accepted, it will be on dockerhub as well, besides the Alpine based docker image.
Thank you for reinstating the ubuntu based docker.
The two-commands I proposed above do not crash, provided I add the libgfortran5 library (apt install libgfortran5).
Nevertheless, I think this is not the latest version of Snap, as I noticed the following error which has since been corrected: Srtm Zip Files are not found.
I don’t manage to update the SNAP modules, I get the following error :
./snap --nosplash --nogui --modules --update-all --refresh
./../platform/lib/nbexec: WARNING: environment variable DISPLAY is not set
Refreshing SNAP Supported Plugins
Refreshing SNAP Core
Refreshing SNAP Toolboxes
Updates not found.
updates=0
whereas there is a long list of available updates:
I have added libgfortran5 to the Alpine flavor (already available from docker hub).
Concerning the updates:
Ubuntu flavor: I see the same, “updates=0”, dunno if that’s right
Alpine flavor: I could add the update command to the Dockerfile but it dies with this error:
SNAP Raster Operators UI
SNAP Standalone Tool Adapter GUI
SNAP Standalone Tool Adapter GUI
null
null
Exception in thread "main" java.lang.NullPointerException
at sun.awt.FontConfiguration.getVersion(FontConfiguration.java:1264)
at sun.awt.FontConfiguration.readFontConfigFile(FontConfiguration.java:219)
at sun.awt.FontConfiguration.init(FontConfiguration.java:107)
at sun.awt.X11FontManager.createFontConfiguration(X11FontManager.java:774)
at sun.font.SunFontManager$2.run(SunFontManager.java:431)
at java.security.AccessController.doPrivileged(Native Method)
at sun.font.SunFontManager.<init>(SunFontManager.java:376)
at sun.awt.FcFontManager.<init>(FcFontManager.java:35)
at sun.awt.X11FontManager.<init>(X11FontManager.java:57)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at sun.font.FontManagerFactory$1.run(FontManagerFactory.java:83)
at java.security.AccessController.doPrivileged(Native Method)
at sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74)
at sun.font.SunFontManager.getInstance(SunFontManager.java:250)
at sun.font.FontDesignMetrics.getMetrics(FontDesignMetrics.java:264)
at sun.swing.SwingUtilities2.getFontMetrics(SwingUtilities2.java:1119)
at javax.swing.JComponent.getFontMetrics(JComponent.java:1617)
at javax.swing.text.PlainView.calculateLongestLine(PlainView.java:639)
at javax.swing.text.PlainView.updateMetrics(PlainView.java:209)
at javax.swing.text.PlainView.updateDamage(PlainView.java:527)
at javax.swing.text.PlainView.insertUpdate(PlainView.java:451)
at javax.swing.plaf.basic.BasicTextUI$RootView.insertUpdate(BasicTextUI.java:1610)
at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.insertUpdate(BasicTextUI.java:1869)
at javax.swing.text.AbstractDocument.fireInsertUpdate(AbstractDocument.java:201)
at javax.swing.text.AbstractDocument.handleInsertString(AbstractDocument.java:748)
at javax.swing.text.AbstractDocument.insertString(AbstractDocument.java:707)
at javax.swing.text.PlainDocument.insertString(PlainDocument.java:130)
at javax.swing.text.AbstractDocument.replace(AbstractDocument.java:669)
at javax.swing.text.JTextComponent.setText(JTextComponent.java:1669)
at org.netbeans.updater.UpdaterFrame.initComponents(UpdaterFrame.java:175)
at org.netbeans.updater.UpdaterFrame.<init>(UpdaterFrame.java:128)
at org.netbeans.updater.UpdaterFrame.main(UpdaterFrame.java:253)
Thank you for adding libgfortran5 to Alpine, but unfortunately, I still have the same issue.
Regarding the updates, I think the one that solved the SRTM problem is included in the latest installer.
Is it possible to use the latest installer to generate the Dockers ?
My mistake. I thought the fix was included in the last installer, but in fact, I applied it by hand with the following command : sed -i 's/DEM.srtm3GeoTiffDEM_HTTP.*/DEM.srtm3GeoTiffDEM_HTTP = http:\/\/skywatch-auxdata.s3-us-west-2.amazonaws.com\/dem\/SRTM90\/tiff\//' /usr/local/snap/etc/snap.auxdata.properties
Now, the two commands runs well. I will do further tests in real conditions.
Thanks a lot for you support !
It’s not the same as the issue SNAP-1367. It’s does not even try to install updates as it does not found any.
Anyway, I tried to install the fonts, but it does not change anything.
I have rebuilt the Alpine based docker image today, still no way to update to SNAP 8.0.3:
docker pull mundialis/esa-snap:s1tbx
docker run -it --rm 9ec75d7c0903 /bin/sh
/ # /usr/local/snap/bin/snap --nosplash --nogui --modules --update-all
/usr/local/snap/bin/../platform/lib/nbexec: WARNING: environment variable DISPLAY is not set
Refreshing SNAP Supported Plugins
Refreshing SNAP Core
Refreshing SNAP Toolboxes
Will update org.csa.rstb.rstb.op.polarimetric.tools@8.0.0 to version 8.0.1
Will update org.esa.snap.snap.temporal.percentile@8.0.0 to version 8.0.3
Will update org.esa.snap.snap.unmix.ui@8.0.0 to version 8.0.3
Will update org.esa.snap.snap.pgx.reader@8.0.0 to version 8.0.3
...
Will update org.esa.snap.snap.ndvi@8.0.0 to version 8.0.3
Will update org.esa.s1tbx.s1tbx.op.calibration@8.0.0 to version 8.0.1
updates=102
Establishing a connection ...
Establishing a connection ...
SNAP Core Library
SNAP Core Library
SNAP Python Interface
SNAP Python Interface
SNAP Remote Products Repository
SNAP Remote Products Repository
SNAP NetCDF Product Reader/Writer
SNAP NetCDF Product Reader/Writer
...
NASA Blue Marble Worldmap
SNAP Help
SNAP Help
null
null
Exception in thread "main" java.lang.NullPointerException
at sun.awt.FontConfiguration.getVersion(FontConfiguration.java:1264)
at sun.awt.FontConfiguration.readFontConfigFile(FontConfiguration.java:219)
at sun.awt.FontConfiguration.init(FontConfiguration.java:107)
at sun.awt.X11FontManager.createFontConfiguration(X11FontManager.java:774)
at sun.font.SunFontManager$2.run(SunFontManager.java:431)
at java.security.AccessController.doPrivileged(Native Method)
at sun.font.SunFontManager.<init>(SunFontManager.java:376)
at sun.awt.FcFontManager.<init>(FcFontManager.java:35)
at sun.awt.X11FontManager.<init>(X11FontManager.java:57)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at sun.font.FontManagerFactory$1.run(FontManagerFactory.java:83)
at java.security.AccessController.doPrivileged(Native Method)
at sun.font.FontManagerFactory.getInstance(FontManagerFactory.java:74)
at sun.font.SunFontManager.getInstance(SunFontManager.java:250)
at sun.font.FontDesignMetrics.getMetrics(FontDesignMetrics.java:264)
at sun.swing.SwingUtilities2.getFontMetrics(SwingUtilities2.java:1119)
at javax.swing.JComponent.getFontMetrics(JComponent.java:1617)
at javax.swing.text.PlainView.calculateLongestLine(PlainView.java:639)
at javax.swing.text.PlainView.updateMetrics(PlainView.java:209)
at javax.swing.text.PlainView.updateDamage(PlainView.java:527)
at javax.swing.text.PlainView.insertUpdate(PlainView.java:451)
at javax.swing.plaf.basic.BasicTextUI$RootView.insertUpdate(BasicTextUI.java:1610)
at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.insertUpdate(BasicTextUI.java:1869)
at javax.swing.text.AbstractDocument.fireInsertUpdate(AbstractDocument.java:201)
at javax.swing.text.AbstractDocument.handleInsertString(AbstractDocument.java:748)
at javax.swing.text.AbstractDocument.insertString(AbstractDocument.java:707)
at javax.swing.text.PlainDocument.insertString(PlainDocument.java:130)
at javax.swing.text.AbstractDocument.replace(AbstractDocument.java:669)
at javax.swing.text.JTextComponent.setText(JTextComponent.java:1669)
at org.netbeans.updater.UpdaterFrame.initComponents(UpdaterFrame.java:175)
at org.netbeans.updater.UpdaterFrame.<init>(UpdaterFrame.java:128)
at org.netbeans.updater.UpdaterFrame.main(UpdaterFrame.java:253)
Will update org.csa.rstb.rstb.op.polarimetric.tools@8.0.0 to version 8.0.1
Will update org.esa.snap.snap.temporal.percentile@8.0.0 to version 8.0.3
Will update org.esa.snap.snap.unmix.ui@8.0.0 to version 8.0.3
Will update org.esa.snap.snap.pgx.reader@8.0.0 to version 8.0.3
...