Big Moose Saloon
 Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics Register / Login Win a copy of Java SE 8 for the Really Impatient this week in the Java 8 forum!

# Error while trying to run Tomcat for servlets

Arjun Reddy
Ranch Hand

Joined: Nov 10, 2007
Posts: 627
Hi,

I tried to run Tomcat by going to the bin directory and typing in startup.bat. When I did that, it gave me the below info:

The JAVA_HOME environment variable is not defined correctly.This environment variable is needed to run this program.
NB: JAVA_HOME should point to a JDK and not a JRE

However, I read through the RUNNING.txt file in the tomcat directory and set two SYSTEM environmental variables.

JAVA_HOME: C:\Program Files\Java\jdk1.5.0_14;
JRE_HOME: C:\Program Files\Java\jre1.5.0_14;

My Class Path contains : C:\Program Files\Java\jdk1.5.0_14\bin; and does not have a JRE in it.

I've set my classpath by right clicking on my computer--> Environment variables.

Any suggestion guys as where I am doing wrong?

Thanks.

Be Humble... Be Nice.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14686

16

Remove the semi-colon after the path.

[My Blog]
Arjun Reddy
Ranch Hand

Joined: Nov 10, 2007
Posts: 627
Hi,

I did that, closed the existing cmd prompt and opened a new command prompt but it still gives me the same error.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14686

16

In the command window you have opened, what is shown when you type SET ?

I agree. Here's the link: http://aspose.com/file-tools

subject: Error while trying to run Tomcat for servlets