Page 1 of 1

JAVA_HOME / JRE_HOME variable missing

PostPosted:Mon Dec 03, 2012 9:40 am
by raiko
Hi, I've installed OpenKM 6.2 community on Ubuntu 12.04 LTS. After issued this command:
Code: Select all
./opt/openkm/tomcat/bin/catalina.sh start
Following error has returned:
Code: Select all
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
From my understanding, OKM installer has JAVA bundled and I shouldn't need to install JAVA by my own. How can I fix it?

Thank You!

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Mon Dec 03, 2012 10:00 am
by miguelromero
I would suggest to install 1.6 Java version for Ubuntu, and test if it works.

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Mon Dec 03, 2012 8:43 pm
by raiko
I followed this page to install JAVA 1.6 and with this errors:
Code: Select all
./jre-6u31-linux-i586.bin: line 1: html: No such file or directory
./jre-6u31-linux-i586.bin: line 2: head: No such file or directory
./jre-6u31-linux-i586.bin: line 3: title: No such file or directory
./jre-6u31-linux-i586.bin: line 4: META: No such file or directory
./jre-6u31-linux-i586.bin: line 5: link: No such file or directory
./jre-6u31-linux-i586.bin: line 6: link: No such file or directory
./jre-6u31-linux-i586.bin: line 7: $'\r': command not found
./jre-6u31-linux-i586.bin: line 8: body: No such file or directory
./jre-6u31-linux-i586.bin: line 9: div: No such file or directory
./jre-6u31-linux-i586.bin: line 10: table: No such file or directory
./jre-6u31-linux-i586.bin: line 11: tr: No such file or directory
./jre-6u31-linux-i586.bin: line 12: syntax error near unexpected token `<'
./jre-6u31-linux-i586.bin: line 12: `      <td rowspan="2" valign="middle" nowrap><a href="http://www.oracle.com"><img src="/errors/us/assets/oralogo-small.gif"'width="154" height="19" hspace="10" vspace="25" border="0" ></a></td>
I also tried to add the JRE_HOME variables manually from terminal:
Code: Select all
JRE_HOME=/opt/openkm/java
And catalina returns the same error.

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Tue Dec 04, 2012 9:11 am
by shaardu
Install jdk 1.7 for tomcat to work!

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Wed Dec 05, 2012 7:08 am
by raiko
I didn't try JDK 1.7 because somewhere mentioned OKM is not compatible with it. Anyway, thanks again shaardu!

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Wed Dec 05, 2012 10:31 am
by shaardu
Try with jdk 1.6 atleast...it works fine ,also you need to set the environment variable!

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Wed Dec 05, 2012 9:46 pm
by raiko
I tried both, see my initial post. Or we are not talking about the same thing?

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Thu Dec 06, 2012 8:42 am
by jllort
For install java in ubuntu take a look here https://help.ubuntu.com/community/Java

About openkm installer, comes with java but this kind of configuration is only to make openkm starting and initial configuration more easy. Really the java installed by openkm bundle does not install at your OS in a normal way, only is exploded and used by openkm start scripts. Here I suppose you installed openkm with installer not .zip

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Sat Dec 08, 2012 5:32 am
by raiko
Yes, I installed openkm with the installer. Unlike the windows version, I don't see there is any starting script. I have seen there was 2 scripts with "desktop" extension, but they have no action after double-click.

Since I have removed ubuntu. This thread can be closed.

Thanks for all the inputs.

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Sat Dec 08, 2012 6:43 pm
by jllort
Seems has been some problem during installation process. Anyway if you want to test other time script to execute from terminal are:
Code: Select all
tomcat/bin/catalina.sh start
tomcat/bin/catalina.sh stop

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Wed Dec 12, 2012 10:16 pm
by raiko
This exactly what I did. Pls see my initial post above. Thanks!

Re: JAVA_HOME / JRE_HOME variable missing

PostPosted:Fri Dec 14, 2012 6:20 pm
by jllort
Seems has been some problem with your installation ? take a look in openkm folder you got java folder and then take a look at tomcat/setenv.sh that JAVA_HOME variable is correctly set, otherside change it.