You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Antonio Rodríguez Anaya <ar...@dia.uned.es> on 2007/10/15 18:46:30 UTC

Problem: stasrtup Tomcat in Mac os X 10.4.2

Hi!

I have problems to start up Tomcat 5.5 and 6.0. I have downloaded  
core binary distributions and I have followed the instructions.

As a root I have unpacked and moved it to /user/local directory. I  
have secified the CATALINA_HOME and JAVA_HOME variables. I have set  
execute permisions to all *.sh files in $CATALINA_HOME/bin/ (chmod ug 
+x *.sh). I have tried to start up Tomcat but it does not work. First  
the message is:
Using CATALINA_BASE:   /usr/local/tomcat-5
Using CATALINA_HOME:   /usr/local/tomcat-5
Using CATALINA_TMPDIR: /usr/local/tomcat-5/temp
Using JRE_HOME:       /usr/bin/java

This is normal, I think, but Tomcat does not work. The catalina.log  
file shows this error message:
/usr/local/tomcat-5/bin/catalina.sh: line 273: /usr/bin/java/bin/ 
java: Not a directory

The catalina.sh file line number 273 is:
  "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \

I understand the value of JAVA_OPTS or CATALINA_OPTS is "/usr/bin/ 
java" and "/bin/java". I think something wrong happends, because I  
had not set either JAVA_OPTS or CATALINA_OPTS. I have tried to set  
these variables with the value "-server -Xmx400m", but the situation  
has not changed. The error message in catalina.log is the same.

I do not understand what happen. Is it possible the problem is for  
the operation system? My os is Mac os X 10.4.2. Does someone know how  
I can correct the problem?

Thanks in advance,

Antonio.
  

Re: Problem: stasrtup Tomcat in Mac os X 10.4.2

Posted by Antonio Rodríguez Anaya <ar...@dia.uned.es>.
Yes, the problem was in the JAVA_HOME.

Thanks,

Toni.

El 15/10/2007, a las 19:26, Steve Ochani escribió:

> Date sent:	Mon, 15 Oct 2007 18:46:30 +0200
> From:	Antonio Rodríguez Anaya <ar...@dia.uned.es>
> Subject:	Problem: stasrtup Tomcat in Mac os X 10.4.2
> To:	users@tomcat.apache.org
> Send reply to:	Tomcat Users List <us...@tomcat.apache.org>
>
>> Hi!
>>
>> I have problems to start up Tomcat 5.5 and 6.0. I have downloaded
>> core binary distributions and I have followed the instructions.
>>
>> As a root I have unpacked and moved it to /user/local directory. I
>> have secified the CATALINA_HOME and JAVA_HOME variables. I have set
>> execute permisions to all *.sh files in $CATALINA_HOME/bin/ (chmod ug
>> +x *.sh). I have tried to start up Tomcat but it does not work. First
>> the message is: Using CATALINA_BASE:   /usr/local/tomcat-5 Using
>> CATALINA_HOME:   /usr/local/tomcat-5 Using CATALINA_TMPDIR:
>> /usr/local/tomcat-5/temp Using JRE_HOME:       /usr/bin/java
>>
>> This is normal, I think, but Tomcat does not work. The catalina.log
>> file shows this error message: /usr/local/tomcat-5/bin/catalina.sh:
>> line 273: /usr/bin/java/bin/ java: Not a directory
>>
>> The catalina.sh file line number 273 is:
>>   "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \
>>
>> I understand the value of JAVA_OPTS or CATALINA_OPTS is "/usr/bin/
>> java" and "/bin/java". I think something wrong happends, because I
>> had not set either JAVA_OPTS or CATALINA_OPTS. I have tried to set
>> these variables with the value "-server -Xmx400m", but the situation
>> has not changed. The error message in catalina.log is the same.
>>
>> I do not understand what happen. Is it possible the problem is for
>> the operation system? My os is Mac os X 10.4.2. Does someone know how
>> I can correct the problem?
>>
>
> The problem is this (from your mail)
>
> /usr/bin/java/bin/ java: Not a directory
>
> Since you set /usr/bin/java as the JAVA_HOME, when it really is the  
> java executable.
>
> You have to set JAVA_HOME var to the directory where the entire  
> java installation is, for ex.
> /usr/jdk1.5.0
>
> I don't know where that could be on Mac os x but do some searching.
>
>
>
>> Thanks in advance,
>>
>> Antonio.
>>
>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Problem: stasrtup Tomcat in Mac os X 10.4.2

Posted by Steve Ochani <oc...@ncc.edu>.
Date sent:	Mon, 15 Oct 2007 18:46:30 +0200
From:	Antonio Rodríguez Anaya <ar...@dia.uned.es>
Subject:	Problem: stasrtup Tomcat in Mac os X 10.4.2
To:	users@tomcat.apache.org
Send reply to:	Tomcat Users List <us...@tomcat.apache.org>

> Hi!
> 
> I have problems to start up Tomcat 5.5 and 6.0. I have downloaded 
> core binary distributions and I have followed the instructions.
> 
> As a root I have unpacked and moved it to /user/local directory. I 
> have secified the CATALINA_HOME and JAVA_HOME variables. I have set 
> execute permisions to all *.sh files in $CATALINA_HOME/bin/ (chmod ug
> +x *.sh). I have tried to start up Tomcat but it does not work. First 
> the message is: Using CATALINA_BASE:   /usr/local/tomcat-5 Using
> CATALINA_HOME:   /usr/local/tomcat-5 Using CATALINA_TMPDIR:
> /usr/local/tomcat-5/temp Using JRE_HOME:       /usr/bin/java
> 
> This is normal, I think, but Tomcat does not work. The catalina.log 
> file shows this error message: /usr/local/tomcat-5/bin/catalina.sh:
> line 273: /usr/bin/java/bin/ java: Not a directory
> 
> The catalina.sh file line number 273 is:
>   "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \
> 
> I understand the value of JAVA_OPTS or CATALINA_OPTS is "/usr/bin/
> java" and "/bin/java". I think something wrong happends, because I 
> had not set either JAVA_OPTS or CATALINA_OPTS. I have tried to set 
> these variables with the value "-server -Xmx400m", but the situation 
> has not changed. The error message in catalina.log is the same.
> 
> I do not understand what happen. Is it possible the problem is for 
> the operation system? My os is Mac os X 10.4.2. Does someone know how 
> I can correct the problem?
> 

The problem is this (from your mail)

/usr/bin/java/bin/ java: Not a directory

Since you set /usr/bin/java as the JAVA_HOME, when it really is the java executable.

You have to set JAVA_HOME var to the directory where the entire java installation is, for ex. 
/usr/jdk1.5.0

I don't know where that could be on Mac os x but do some searching. 



> Thanks in advance,
> 
> Antonio.
> 



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Problem: stasrtup Tomcat in Mac os X 10.4.2

Posted by Filip Hanik - Dev Lists <de...@hanik.com>.
Using JRE_HOME:       /usr/bin/java

JRE_HOME or JAVA_HOME should point to a directory, not an executable

Filip

Antonio Rodríguez Anaya wrote:
> Hi!
>
> I have problems to start up Tomcat 5.5 and 6.0. I have downloaded core 
> binary distributions and I have followed the instructions.
>
> As a root I have unpacked and moved it to /user/local directory. I 
> have secified the CATALINA_HOME and JAVA_HOME variables. I have set 
> execute permisions to all *.sh files in $CATALINA_HOME/bin/ (chmod 
> ug+x *.sh). I have tried to start up Tomcat but it does not work. 
> First the message is:
> Using CATALINA_BASE:   /usr/local/tomcat-5
> Using CATALINA_HOME:   /usr/local/tomcat-5
> Using CATALINA_TMPDIR: /usr/local/tomcat-5/temp
>
>
> This is normal, I think, but Tomcat does not work. The catalina.log 
> file shows this error message:
> /usr/local/tomcat-5/bin/catalina.sh: line 273: /usr/bin/java/bin/java: 
> Not a directory
>
> The catalina.sh file line number 273 is:
>  "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \
>
> I understand the value of JAVA_OPTS or CATALINA_OPTS is 
> "/usr/bin/java" and "/bin/java". I think something wrong happends, 
> because I had not set either JAVA_OPTS or CATALINA_OPTS. I have tried 
> to set these variables with the value "-server -Xmx400m", but the 
> situation has not changed. The error message in catalina.log is the same.
>
> I do not understand what happen. Is it possible the problem is for the 
> operation system? My os is Mac os X 10.4.2. Does someone know how I 
> can correct the problem?
>
> Thanks in advance,
>
> Antonio.
>  
> ------------------------------------------------------------------------
>
> No virus found in this incoming message.
> Checked by AVG Free Edition. 
> Version: 7.5.488 / Virus Database: 269.14.10/1070 - Release Date: 10/14/2007 9:22 AM
>   


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Problem: stasrtup Tomcat in Mac os X 10.4.2

Posted by Pid <p...@pidster.com>.
Antonio Rodríguez Anaya wrote:
> Hi!
> 
> I have problems to start up Tomcat 5.5 and 6.0. I have downloaded core
> binary distributions and I have followed the instructions.
> 
> As a root I have unpacked and moved it to /user/local directory. I have
> secified the CATALINA_HOME and JAVA_HOME variables. I have set execute
> permisions to all *.sh files in $CATALINA_HOME/bin/ (chmod ug+x *.sh). I
> have tried to start up Tomcat but it does not work. First the message is:
> Using CATALINA_BASE:   /usr/local/tomcat-5
> Using CATALINA_HOME:   /usr/local/tomcat-5
> Using CATALINA_TMPDIR: /usr/local/tomcat-5/temp
> Using JRE_HOME:       /usr/bin/java
> 
> This is normal, I think, but Tomcat does not work. The catalina.log file
> shows this error message:
> /usr/local/tomcat-5/bin/catalina.sh: line 273: /usr/bin/java/bin/java:
> Not a directory
> 
> The catalina.sh file line number 273 is:
>  "$_RUNJAVA" $JAVA_OPTS $CATALINA_OPTS \
> 
> I understand the value of JAVA_OPTS or CATALINA_OPTS is "/usr/bin/java"
> and "/bin/java". I think something wrong happends, because I had not set
> either JAVA_OPTS or CATALINA_OPTS. I have tried to set these variables
> with the value "-server -Xmx400m", but the situation has not changed.
> The error message in catalina.log is the same.
> 
> I do not understand what happen. Is it possible the problem is for the
> operation system? My os is Mac os X 10.4.2. Does someone know how I can
> correct the problem?

JAVA_HOME is not meant to be the location of the Java binary.
It is meant to be the location of the Java installation directory.

The script add "/bin/java" to the JAVA_HOME value to get the path to the
executable, which is why you're seeing "/usr/bin/java/bin/java"

First, try unsetting (ie not setting) the JAVA_HOME variable, and see if
OS X can work it out for itself (which it seems to in later/recent
versions).


If this does not work, set JAVA_HOME to be "/Library/Java/Home", which
is an alias for the default Java installation directory on OS X.


(If you have multiple Java installs and wish to choose one, reply &
we'll sort that out later.)

p





> Thanks in advance,
> 
> Antonio.
>  


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org