[greenstone_es] Re: Error al ejecutar GLI

  • From: Patricio Carranza <pcarranza@xxxxxxxxxxxxxxxx>
  • To: greenstone_es@xxxxxxxxxxxxx
  • Date: Mon, 30 Jan 2017 15:54:42 -0300

Diego, hice los cambios en el archivo greenstone/gli/gli.sh y el resultado
ahora es este:

pcarranza@bpd-1:~/Greenstone3/gli$ ./gli.sh./gli.sh: line 1: #!/bin/bash:
No such file or directoryGreenstone Librarian Interface (GLI)Copyright (C)
2006, New Zealand Digital Library Project, University Of WaikatoGLI comes
with ABSOLUTELY NO WARRANTY; for details see LICENSE.txtThis is free
software, and you are welcome to redistribute itBoth Greenstone 2 and
Greenstone 3 environments are set.It is assumed you want to run Greenstone
3.If you want to run Greenstone 2, please unset theenvironment variable
GSDL3SRCHOME before running GLI.Greenstone version found: 3Checking GSDL3:
/home/pcarranza/Greenstone3GSDLHOME environment variable is set to
/home/pcarranza/Greenstone3/gs2build.Will use this to find build
scripts.Checking
GSDL: /home/pcarranza/Greenstone3/gs2buildGSDL3SRCHOME is:
/home/pcarranza/Greenstone3GSDL3HOME is:
/home/pcarranza/Greenstone3/webGSDLHOME
is: /home/pcarranza/Greenstone3/gs2buildPerl:/usr/bin/perlImageMagick
bundled with Greenstone will be used, if you wish to use the version
installed on your system (if any) please go to
/home/pcarranza/Greenstone3/gs2build/bin/linux and rename the folder called
imagemagick to something else.Running the Greenstone Librarian
Interface...Version:
3.08Exception in thread "main" java.lang.ExceptionInInitializerError at
org.greenstone.gatherer.Gatherer.init(Gatherer.java:283) at
org.greenstone.gatherer.Gatherer.<init>(Gatherer.java:233) at
org.greenstone.gatherer.GathererProg.main(GathererProg.java:78)Caused by:
java.awt.HeadlessException: No X11 DISPLAY variable was set, but this
program performed an operation which requires it. at
sun.awt.HeadlessToolkit.getScreenSize(HeadlessToolkit.java:284) at
org.greenstone.gatherer.Configuration.<clinit>(Configuration.java:112) ...
3 moreDone.

¿Hay algo más que deba corregir?

Gracias y saludos,

Patricio




2017-01-30 15:36 GMT-03:00 Diego Spano <diegospano@xxxxxxxxx>:

Hagamos entonces esto. Editá el archivo greenstone/gli/gli.sh y reemplazá
todas las ocurrencias de "$javapath" por 
"/usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java".
Por ejemplo, la linea:

"$javapath" -Xmx128M -classpath classes/:GLI.jar:lib/apache.
jar:lib/qfslib.jar:lib/rsyntaxtextarea.jar $custom_vm_args.............

quedaría:

"/usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java" -Xmx128M -classpath
classes/:GLI.jar:lib/apache.jar:lib/qfslib.jar:lib/rsyntaxtextarea.jar
$custom_vm_args.............

Por otro lado, en la linea 80 aprox hay un bloque como este:


## ---- Check Java ----
# call the script with source, so that we have the variables it sets
($javapath)
exit_status=0
source ./findjava.sh "$glilang" "$PROGNAME"
exit_status=$?
if [ "$exit_status" -eq 1 ]; then
    exit 1;
fi


Comentá todas las líneas para que no intente buscarte el JAVA, ya que se
lo forzaste en el paso anterior:


## ---- Check Java ----
# call the script with source, so that we have the variables it sets
($javapath)
#exit_status=0
#source ./findjava.sh "$glilang" "$PROGNAME"
#exit_status=$?
#if [ "$exit_status" -eq 1 ]; then
#    exit 1;
#fi







Saludos!


*Diego Spano* *Director de Proyectos, Prodigio Consultores*
Tel: (54 11) 5274-8413

Argentina
dspano@xxxxxxxxxxxxxxxxxxxxxxx | www.prodigioconsultores.com
<http://s.wisestamp.com/links?url=http%3A%2F%2Fwww.prodigioconsultores.com%2F&sn=ZGllZ29zcGFub0BnbWFpbC5jb20%3D>
Contact me: [image: Skype] diegospano

<http://s.wisestamp.com/links?url=http%3A%2F%2Fwww.linkedin.com%2Fin%2Fdiegospano&sn=ZGllZ29zcGFub0BnbWFpbC5jb20%3D>


On Mon, Jan 30, 2017 at 3:18 PM, Patricio Carranza <
pcarranza@xxxxxxxxxxxxxxxx> wrote:

Diego, gracias como siempre por tu ayuda.

Volví a setear el JAVA_HOME y quedó así:

pcarranza@bpd-1:~/Greenstone3/gli$ echo $JAVA_HOME/usr/lib/jvm/java-8-
openjdk-amd64/jre

Sin embargo, cuando ejecuto ./gli.sh me devuelve el siguiente error:

pcarranza@bpd-1:~/Greenstone3/gli$ ./gli.shGreenstone Librarian
Interface (GLI)Copyright (C) 2006, New Zealand Digital Library Project,
University Of WaikatoGLI comes with ABSOLUTELY NO WARRANTY; for details
see LICENSE.txtThis is free software, and you are welcome to
redistribute itBoth Greenstone 2 and Greenstone 3 environments are set.It
is assumed you want to run Greenstone 3.If you want to run Greenstone 2,
please unset theenvironment variable GSDL3SRCHOME before running 
GLI.Greenstone
version found: 3Checking GSDL3: /home/pcarranza/Greenstone3GSDLHOME
environment variable is set to /home/pcarranza/Greenstone3/gs2build.Will
use this to find build scripts.Checking GSDL:
/home/pcarranza/Greenstone3/gs2buildGSDL3SRCHOME is:
/home/pcarranza/Greenstone3GSDL3HOME is: 
/home/pcarranza/Greenstone3/webGSDLHOME
is: /home/pcarranza/Greenstone3/gs2buildPerl:/usr/bin/perlFailed to
locate an appropriate version of Java. You must install aJava Runtime
Environment (version 1.4 or greater) before running theGreenstone
Librarian Interface.If you have Java installed on your machine please
set the environment variable JAVA_HOME.

En /etc/*environment *tengo lo siguiente:

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbi
n:/bin:/usr/games:/usr/local/games"PATH=$PATH:/usr/lib/jvm/
java-8-openjdk-amd64/jreexport PATHJAVA_HOME="/usr/lib/jvm/ja
va-8-openjdk-amd64/jre"export JAVA_HOME

No logro darme cuenta qué puede estar causando que no encuentre la
instalación de Java.

Gracias de antemano por la ayuda que puedas brindarme.

Saludos!

Patricio



2017-01-30 12:59 GMT-03:00 Diego Spano <diegospano@xxxxxxxxx>:

Patricio, creo que el JAVA_HOME está mal seteado. Configuralo así:

$JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/jre

y probá.


Saludos!


*Diego Spano* *Director de Proyectos, Prodigio Consultores*
Tel: (54 11) 5274-8413

Argentina
dspano@xxxxxxxxxxxxxxxxxxxxxxx | www.prodigioconsultores.com
<https://mailtrack.io/trace/link/eb7ab6a66140397bac25a69c0776f972b2cc9681?url=http%3A%2F%2Fs.wisestamp.com%2Flinks%3Furl%3Dhttp%253A%252F%252Fwww.prodigioconsultores.com%252F%26sn%3DZGllZ29zcGFub0BnbWFpbC5jb20%253D&signature=74a09dbf9be83d69>
Contact me: [image: Skype] diegospano

<https://mailtrack.io/trace/link/789b68ad5802212a0b87ba7f8ebff517eca58479?url=http%3A%2F%2Fs.wisestamp.com%2Flinks%3Furl%3Dhttp%253A%252F%252Fwww.linkedin.com%252Fin%252Fdiegospano%26sn%3DZGllZ29zcGFub0BnbWFpbC5jb20%253D&signature=199fda2fe600f8c7>


On Sat, Jan 28, 2017 at 2:39 PM, Patricio Carranza <
pcarranza@xxxxxxxxxxxxxxxx> wrote:

Hola!
Instalé Greenstone 3 en Ubuntu 16.04 sin problemas. Sin embargo, cuando
ejecuto el comando ./gli.sh me dice que no encuentra una instalación de
Java, aunque sí está instalado.
El comando echo $JAVA_HOME responde con /usr/lib/jvm/java-8-openjdk-am
d64/jre/bin/java

Agradezco de antemano la ayuda que puedan brindarme.

Patricio


pcarranza@bpd-1:~/Greenstone3/gli$ ./gli.shGreenstone Librarian
Interface (GLI)Copyright (C) 2006, New Zealand Digital Library
Project, University Of WaikatoGLI comes with ABSOLUTELY NO WARRANTY;
for details see LICENSE.txtThis is free software, and you are welcome
to redistribute itGreenstone version found: 3Checking GSDL3:
/home/pcarranza/Greenstone3Setting up your environment for Greenstone3
- Exported GSDL3HOME, GSDL3SRCHOME and GSDLOS - Adjusted PATH -
Adjusted MANPATH - Adjusted CLASSPATH - Adjusted LD_LIBRARY_PATH and
DYLD_LIBRARY_PATH - Setup Greenstone ant (/home/pcarranza/Greenstone3/p
ackages/ant)Sourcing gs2build/setup.bashYour environment has
successfully been set up to run Greenstone+Your environment is now
setup for the PDFBox ExtensionSOLR port: 8383SOLR host: localhost+Your
environment is now setup for the Solr Extension++Solr will run off the
tomcat server on port 8383. -- This port value can be changed by
editing tomcat.port in build.properties - ERROR: Failed to locate java
1.5.0_00 or greater Please set JAVA_HOME or JRE_HOME to point to an
appropriate java And add JAVA_HOME/bin or JRE_HOME/bin to your PATHGSDLHOME
environment variable is set to /home/pcarranza/Greenstone3/gs2build.Will
use this to find build scripts.Checking GSDL:
/home/pcarranza/Greenstone3/gs2buildGSDL3SRCHOME is:
/home/pcarranza/Greenstone3GSDL3HOME is: /home/pcarranza/Greenstone3/we
bGSDLHOME is: /home/pcarranza/Greenstone3/gs2buildPerl:/usr/bin/perlFailed
to locate an appropriate version of Java. You must install aJava
Runtime Environment (version 1.4 or greater) before running theGreenstone
Librarian Interface.If you have Java installed on your machine please
set the environment variable JAVA_HOME.









Other related posts: