gvSIG bugs #3023

"Java Virtual Machine Launcher" error after install

Added by Antonio Falciano over 9 years ago. Updated over 8 years ago.

Status:Won't fix% Done:

0%

Priority:NormalSpent time:-
Assignee:-
Category:Application
Target version:2.3.0-2413 (rev. org.gvsig.desktop-2.0.119)
Severity:Blocker Add-on version:
gvSIG version:2.1.0 Add-on build:
gvSIG build:2257 Add-on resolve version:
Operative System:Windows Add-on resolve build:
Keywords: Proyecto:
Has patch: Hito:
Add-on name:Unknown

Description

After a fresh install of build 2257, a "Java Virtual Machine Launcher" error occurs and gvSIG can't be executed, even if with elevated permissions.

jvm_error_2257.png (42.8 KB) Antonio Falciano, 11/24/2014 03:44 AM

gvSIG-installer_2257.log (74.1 KB) Antonio Falciano, 11/24/2014 03:48 AM

launch4j.log (2.15 KB) Antonio Falciano, 11/26/2014 05:51 AM

launch4j_error.log (6.45 KB) Antonio Falciano, 11/26/2014 12:17 PM

1178

Associated revisions

Revision 41855
Added by Joaquín del Cerro Murciano over 9 years ago

refs #3023. "Java Virtual Machine Launcher" error after install

Revision 41902
Added by Joaquín del Cerro Murciano over 9 years ago

refs #2807, refs #3023, corregido un problema al determinar si se podia escribir en el repositorio de paquetes, en Windows, el File.canWrite retorna true aunque no pueda escribirse.

Revision 41905
Added by Joaquín del Cerro Murciano over 9 years ago

refs #3023, actualizada la version del jre a usar a la 1.7.0.72

History

#1 Updated by Antonio Falciano over 9 years ago

Further info: the gvSIG.log is not created, but I see that there's an error in the gvSIG-installer.log about the translations package.

#2 Updated by Álvaro Anguix over 9 years ago

En Linux funciona bien.

#3 Updated by Mario Carrera over 9 years ago

Hi Antonio, this solution has been sent to the the Spanish mailing list by other user: http://www.tomsguide.com/faq/id-1761312/fix-create-java-virtual-machine-issue.html. Does it fix the error?

#4 Updated by Antonio Falciano over 9 years ago

Mario Carrera wrote:

Hi Antonio, this solution has been sent to the the Spanish mailing list by other user: http://www.tomsguide.com/faq/id-1761312/fix-create-java-virtual-machine-issue.html. Does it fix the error?

Hi Mario,
this issue happens randomly in the latest builds after a successful install too, as some other users report. I usually bypass it restarting the machine (as I did this morning), but it's only a temporal solution and further very annoying. Thank you very much for the hint, but I don't know if setting _JAVA_OPTIONS=-Xmx512M could overwrite the gvSIG memory management (for instance, -Xmx1024M).

#5 Updated by Joaquín del Cerro Murciano over 9 years ago

Antonio Falciano wrote:

Mario Carrera wrote:

Hi Antonio, this solution has been sent to the the Spanish mailing list by other user: http://www.tomsguide.com/faq/id-1761312/fix-create-java-virtual-machine-issue.html. Does it fix the error?

Hi Mario,
this issue happens randomly in the latest builds after a successful install too, as some other users report. I usually bypass it restarting the machine (as I did this morning), but it's only a temporal solution and further very annoying. Thank you very much for the hint, but I don't know if setting _JAVA_OPTIONS=-Xmx512M could overwrite the gvSIG memory management (for instance, -Xmx1024M).

Me temo que la opcion que apunta mario no sirve. gvSIG usa su propia JRE y configuracion de memoria.

En mi equipo no puedo reproducir el problema.
Si alguno puede reproducirlo que pruebe a ejecutar gvSIG desde linea de comandos con el parametro --l4j-debug-all.

C:\Archivos de programa\gvSIG desktop 2.1.0-2257>gvsig-desktop.exe --l4j-debug-all

y me adjunte al ticket el fichero "launch4j.log" que se habra creado en la misma carpeta donde esta el gvsig-desktop.exe, a ver si ahi se puede ver algo de que puede estar pasando.

#6 Updated by Antonio Falciano over 9 years ago

Hi Joaquín,
this issue probably depends by the launch4j, because the maximum memory value is not initialized in the gvsig-desktop.l4j.ini file, so we could set the default value as -Xmx512m, like in the past (gvSIG.ini). Then the user can change this value manually or with the new Memory plugin (Native preferences) according to his needs.

#7 Updated by Joaquín del Cerro Murciano over 9 years ago

Antonio Falciano wrote:

Hi Joaquín,
this issue probably depends by the launch4j, because the maximum memory value is not initialized in the gvsig-desktop.l4j.ini file, so we could set the default value as -Xmx512m, like in the past (gvSIG.ini). Then the user can change this value manually or with the new Memory plugin (Native preferences) according to his needs.

Si no se indica nada en el fichero "gvsig-desktop.l4j.ini", los valores por defecto de Xmx y Xms son:

  • Xms = 512 Mb (initialHeapSize)
  • Xmx = 1024mb (maxHeapSize)

(Pueden consultarse, que no modificarse, en el fichero gvsig-desktop.xml)

El valor de Xmx es la cantidad de memoria maxima a utilizar por la aplicacion. No quiere decir que esta se reserve al arrancar, si no que conforme se vaya consumiendo se ira reservando hasta llegar a 1024mb, y si se pide mas la aplicacion falla. Reducir este valor no deberia afectar en el arranque de gvSIG, aunque si en su posterior funcionamiento.

El valor de Xms es la memoria que se reserva inicialmente.

Con esta configuracion, si ejecutamos gvSIG con menos de 512mb libres de RAM, probablemente no arranque por falta de memoria, pero no parece razonable arrancar gvSIG con menos memoria.

Los actuales valores por defecto de Xms y Xmx llevan asi bastantes meses. No creo que tengan que ver con el fallo.

#8 Updated by Álvaro Anguix over 9 years ago

Hi Antonio,

gvSIG works ok in several Windows that I tested.
Please, can you execute gvSIG since command line:
C:\Archivos de programa\gvSIG desktop 2.1.0-2257>gvsig-desktop.exe --l4j-debug-all

...and after add the file "launch4j.log"

Thanks!

#9 Updated by Antonio Falciano over 9 years ago

Álvaro Anguix wrote:

gvSIG works ok in several Windows that I tested.

Hi Alvaro,
it works fine now. The issue happened only after the install (and also with other previous builds, like 2255).

Please, can you execute gvSIG since command line:
C:\Archivos de programa\gvSIG desktop 2.1.0-2257>gvsig-desktop.exe --l4j-debug-all

...and after add the file "launch4j.log"

Here's in attachment (it requires elevated permissions in that folder). It seems ok except that there's a duplicated -Xmx1024m between the Launcher args.

#10 Updated by Joaquín del Cerro Murciano over 9 years ago

Buscando por la web he encontrado este documento...

http://www.phacai.com/launch4j-tmp-how-launch4j-achieves-custom-process-name-with-a-temporary-launcher

Lo que cuenta es que para que en el administrador de tareas de windows aparezca "gvsig-desktop.exe" en lugar de java genera un fichero en launch4j-tmp/gvsig-desktop.exe si no existe.
Si el usuario no tiene permiso de escribir en esa ubicacion no se lo que hara, supongo que fallara.
Esto justificaria que una vez arrancado como administrador, se crearia el fichero, y las siguientes veces, aunque no se fuese administrador como ya estaria creado ya funcionaria.

Voy a ver de modificar la configuracion del launch4j para que no cree ese fichero temporal aunque ya no aparezca en el administrador de procesos de windows como gvSIG.

<customProcName>false</customProcName>

Tambien me ha ayudado a entender mejor las cosas este documento:

http://stackoverflow.com/questions/11799446/lauch4j-doesnt-copy-launcher

#11 Updated by Antonio Falciano over 9 years ago

It happens again always with the same installation, so I should restart the machine again... I attach a new launch4j.log.

#12 Updated by Joaquín del Cerro Murciano over 9 years ago

  • Target version changed from 2.1.0-2259-rc3 to 2.1.0-2268-rc4

#13 Updated by Antonio Falciano over 9 years ago

It happened with the RC3 too. Then I've simply switched my JAVA_HOME environment variable from a recent JDK (1.7.0_67) to the latest JRE7 (1.7.0_71) and gvSIG has restarted successfully without restarting the machine this time.

#14 Updated by Antonio Falciano over 9 years ago

Same error randomly with build 2259 and 2260 (after the install).

#15 Updated by Antonio Falciano over 9 years ago

Reported by Alonso Morilla in the gvSIG Usuarios mailing list:
http://listserv.gva.es/pipermail/gvsig_usuarios/2014-December/029070.html

#16 Updated by Antonio Falciano over 9 years ago

Antonio Falciano wrote:

Reported by Alonso Morilla in the gvSIG Usuarios mailing list:
http://listserv.gva.es/pipermail/gvsig_usuarios/2014-December/029070.html

I've reproduced the issue reported by Alonso with the latest version of OOo (4.1.1) in Windows 7 64bit. If I close OOo, then gvSIG is executed regularly.

#17 Updated by Joaquín del Cerro Murciano over 9 years ago

El problema del OOo no se si tiene que ver con el resto del ticket.
De momento he dejado eso aparte (tal vez deberia ser otro ticket distinto ya que parece un problema de memoria).
Me he instalado un windows 7 profesional, me he creado un usuario sin privilegios de administrador y he intentdo instalarme el build 2261.
No he tenido mayores problemas para hacerlo, y la instalacion ha arrancado sin problemas a la primera. He repetido el proceso varias veces y no he conseguido que me falle.
He corregido un error deribado de la falta de permisos en windows relacionado con intentar instalar desde el administrador de complementos plugins, y ahora ya deberia funcionar correctamente.
Por si tuviese que ver con la version del jre usado he actualizado a la 1.7.0.72.

#18 Updated by Joaquín del Cerro Murciano over 9 years ago

  • Target version changed from 2.1.0-2268-rc4 to 2.1.0-2262

#19 Updated by Joaquín del Cerro Murciano over 9 years ago

  • Status changed from New to Fixed

#20 Updated by Antonio Falciano over 9 years ago

  • Status changed from Fixed to Closed

Hi Joaquín,
I've updated the system JRE and installed build 2062 successfully.
Also the issue with OOo seems to be disappeared.
I close the ticket.

#21 Updated by Antonio Falciano over 9 years ago

For future reference: the issue has occurred also in build 2262 with Eclipse in execution on a Windows 7, 64 bits, 8 GB RAM.
gvsig-desktop:r41855 can be reverted in my humble opinion.

#22 Updated by Antonio Falciano almost 9 years ago

  • Target version changed from 2.1.0-2262 to 2.3.0-2400 (rev. org.gvsig.desktop-2.0.102)
  • Status changed from Closed to New

This issue sometimes happens also with gvSIG 2.2 builds, after the install or not. It seems to depend by the amount of the available physical memory. In detail, I've observed that if it's less of about 50%, the "Java Virtual Machine Launcher" error occurs. A workaround consists into closing other applications which use too much memory, e.g. Firefox, in order to lower the used physical memory. Hope this helps to find a robust solution.

#23 Updated by Joaquín del Cerro Murciano almost 9 years ago

  • Target version changed from 2.3.0-2400 (rev. org.gvsig.desktop-2.0.102) to 98

#24 Updated by Álvaro Anguix over 8 years ago

  • Status changed from New to Won't fix

With the new installer, this bug doesn't make sense.

#25 Updated by Joaquín del Cerro Murciano over 8 years ago

  • Target version changed from 98 to 2.3.0-2413 (rev. org.gvsig.desktop-2.0.119)

Also available in: Atom PDF