Failure of gpt on Windows 7

Trying to run a Sentinel-1/GRD pre-processing graph on Windows with gpt (SNAP version 5.0.8) produces a strange error message:

WARNING: java.util.prefs.WindowsPreferences: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(…) returned error code 5.

Then the graph stays active (in task manger), but nothing comes out of the run in more than half a day. I managed to run the same graph in the GUI version of SNAP. I also manged to run it on Linux (SNAP version 6.0) even though it did not respect the choice of polarisations (only produced VV instead of VH,VV).

Why does gpt need to access Windows registry in the first place ?


I have found this stackoverflow entry. It seems there is also a related java bug. But I think we don’t write to the system tree.
Actually it is only a warning and the process should run further.
The reason why it takes so long to process might be the memory settings. Maybe you need to increase the heap space settings or increase the cache size.
you can edit the gpt.vmoptions to increase amount of memory gpt can use and you can use the -c option of gpt to increase the cache.

If you type: gpt --diag you will see the current configuration

Thank you marpet. From some previous discussions and from some other threads on memory issues, I had the impression that all these memory specification things are there, but they do not have any influence on gpt. Now at least the gpt -c argument and the -Xmx argument in the vmoptions file seem to work also with gpt. It is just a pity that default values of memory specifications lead to a silent endless (practically endless - maybe it would complete in some weeks or months) loop on Windows platforms. Now I managed to run my script in gpt both on Windows and on Linux when allocating 8G to both heap and cache. For some strange reason, I had to specify -Xmx9G in the vm options file to increase the max memory value to 8G.

To make both VV and VH go through, I had to balance the cache down to 4G, otherwise I got error messages “Error: GC overhead limit exceeded” and the run stopped.

I interpret your reference to the stackoverflow article so that you suggest SNAP to move to java 9 :slight_smile:


If you make the cache size the same size as the heap there is nothing left for other things as for the data.
I experienced that the best settings are heap=75% of RAM and cache=75% of heap.

The default settings will be better with SNAP v6.

Java 9 is out just a few day. So We will probably not switch very fast. This might cause other new issues.
I haven’t seen this message till now. Maybe you have very restrict system settings?
As far as I know we don’t access the system tree of the windows registration.