Can't start SNAP v.12

Good afternoon, @hriston_bg

Not a problem for us. Keep calm and continue your work. :wink:

No. Our test machine where we try to reproduce your issue, is accessed via the remote desktop connection.

Best regards
Adrian

  1. The content of C:\Users{user}\.snap after getting the error can be seen below

  2. the size of the following directories:

C:\Program Files\esa-snap -
image

C:\Users{user}.snap
image

C:\Users{user}\AppData\Roaming\SNAP
image

  1. Output of the execution for the following command, in a windows terminal (CMD): cd C:\Program Files\esa-snap\bin && snap64.exe

I hope this fine for now.

@hriston_bg
Thank you for providing the requested information. :wink:

We continue the investigation and we will come back with the result of the investigation or we request more information when needed.

Best regards
Adrian

Dear Hristo,

Could you also attach the content of the C:\Program Files\esa-snap\etc\snap.conf file?

Thank you,
Diana

@diana_harosa please find below the content of the CONF file

${HOME} will be replaced by user home directory according to platform

default_userdir=“${HOME}\SNAP”

Options used by the launcher by default, can be overridden by explicit command line switches

default_options=“–branding snap --locale en_GB -J-Xverify:none -J-Xms256M -J-Xmx44G -J-Dnetbeans.mainclass=org.esa.snap.main.Main -J-Dsun.java2d.noddraw=true -J-Dsun.awt.nopixfmt=true -J-Dsun.java2d.dpiaware=false -J-Djava.security.manager=allow -J–add-opens=java.base/java.net=ALL-UNNAMED -J–add-opens=java.desktop/sun.awt=ALL-UNNAMED -J–add-opens=java.base/java.security=ALL-UNNAMED -J–add-opens=java.desktop/javax.swing=ALL-UNNAMED -J–add-opens=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED -J–add-opens=java.desktop/sun.java2d=ALL-UNNAMED”

for development purposes you may wish to append: -J-Dnetbeans.logger.console=true -J-ea

Default location of JRE

jdkhome=“./jre”

Extra cluster paths separated by semicolon ‘;’

#extra_clusters=“”

Sorry, but the file itself can’t be attached directly.

@hriston_bg
The result of our investigation:

Comparing the information you provided with the contents from our test machine, give us what we expected.

This information provide us the first relevant hint for the source of your issue.

During the investigation we understand that the VM option ‘MaxPermSize’ is always present on the startup arguments, according to the SNAP log file, and its presence does not affect the SNAP application startup.
The internal JRE from SNAP uses BellSoft OpenJDK 64-Bit Server VM 21.0.6+10-LTS, which ignores the VM option ‘MaxPermSize’.

We cannot managed to reproduce your issue.
Some strange and unknown things occurs on your system, which prevents the JVM to start, and challenge us to find them.

We need more information about your system, to understand what happened.

:question: Please let us the output of the execution for the following command, in a windows terminal (CMD): cd C:\Program Files\esa-snap\bin && echo %JAVA_HOME%
:question: Please let us the output of the execution for the following command, in a windows terminal (CMD): cd C:\Program Files\esa-snap\bin && echo %PATH%

Best regards
Adrian

Sorry for the delay.

Please find the executed commands

Good afternoon @hriston_bg,

Thank you for providing all the information we requested. :wink:

We come back with the results of our investigation using all the information you provided to us:

Finally, we managed to reproduce your issue using a fresh machine with Windows 10 Pro, created yesterday evening, where we not installed any version of java, and proceed with the installation of SNAP 12. After the installation we close the application and try to start it from the shortcut on the desktop, and now, your issue happened on our machine. We checked the output of the cd C:\Program Files\esa-snap\bin && snap64.exe, and it matches the output from your system.
During the investigation we understand that the executable snap64.exe contains the VM argument -J-XX:MaxPermSize=384m, which prevents the internal JRE to startup the SNAP 12 application on the “fresh” systems (where the JRE/JDK was not installed ever).
We will remove the VM argument -J-XX:MaxPermSize=384m from the snap64.exe executable, to fix this issue.
Until a solution will be found and released, we managed to find a quick and simple workaround to this issue, which will fix it on the systems where this issue occurs.

The workaround solution for your issue is:

:arrow_right: Download and install the MSI installer for BellSoft Liberica Standard JRE 21.0.7+9 x86 64 for Windows, from the official website: https://download.bell-sw.com/java/21.0.7+9/bellsoft-jre21.0.7+9-windows-amd64.msi.
After the installation is finished, you can try to launch the SNAP 12 application and, now, it should gets working.

We’re waiting for the good news from you! :wink:

Best regards
Adrian

1 Like

@adraghici @diana_harosa

Thank you very much to the whole SNAP development team!!!
It works really fine.

1 Like

That was timely. I just started creating the PSADT package for Swap 12 for the fall semester. Is there an ETA for a corrected version? Are we talking about days, weeks or months?
Because updating the packages from the command line does not work even with the workaround, but it is important for us because we install everything automatically.

Thank you.

Hi Joerg,

Could you please provide the command you’re using to update SNAP from the command line, along with the error message you’re encountering
Thank you!
Diana

From the PowerShell:

PS C:\Program Files\esa-snap\bin> & .\snap64.exe --nosplash --nogui --modules --update-all
The launcher has determined that the parent process has a console and will reuse it for its own console output.
Closing the console will result in termination of the running program.
Use ‘–console suppress’ to suppress console output.
Use ‘–console new’ to create a separate console window.
OpenJDK 64-Bit Server VM warning: Options -Xverify:none and -noverify were deprecated in JDK 13 and will likely be removed in a future release.
Unrecognized VM option ‘MaxPermSize=384m’
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

Thank you Diana.

Could you please add the internal JRE path (C:\Program Files\esa-snap\jre\bin) to the Path environment variable and check if the update works?

This works, i just get:

WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.netbeans.TopSecurityManager (file:/C:/Program%20Files/esa-snap/platform/lib/boot.jar)
WARNING: Please consider reporting this to the maintainers of org.netbeans.TopSecurityManager
WARNING: System::setSecurityManager will be removed in a future release

So with the following updateScript (updateSnap.ps1):

$env:path += ';C:\Program Files\esa-snap\jre\bin'
Start-Process "C:\Program Files\esa-snap\bin\snap64.exe" -ArgumentList "--nosplash --nogui --modules --install org.esa.smostbx.*" -NoNewWindow -Wait
& "C:\Program Files\esa-snap\bin\snap64.exe" --nosplash --nogui --modules --update-all 2>&1 | ForEach-Object {
  $line = $_
  if ($line -eq "updates=0") {
     Start-Sleep -Seconds 2
     Get-Process | Where-Object { $_.Path -like "*snap\jre\jre\bin\java*" } | Stop-Process -Force
  }
}

and an installed:

BellSoft Liberica Standard JRE 21.0.7+9 x86 64

the installation works.

The question remains whether there will be a new installer soon or whether I should start the semester like this?

Thank you.