Solved

Tomcat startup.bat error

Posted on 2012-03-28
12
632 Views
Last Modified: 2012-03-28
I am running:

C:\>Program Files\Apache Software Foundation\Tomcat 5.0\bin\startup.bat
'Program' is not recognized as an internal or external command,
operable program or batch file.

I suspect my envrionment setting is not correct. This is what I have for my local environment settings:
:
CATALINA_HOME
C:\Program Files\Apache Software Foundation\Tomcat 5.0\

CLASSPATH
C:\Program Files\Apache Software Foundation\Tomcat 5.0\common\lib\;C:\j2sdk1.4.2_01\bin

JAVA_HOME
C:\j2sdk1.4.2_01

PATH
C:\j2sdk1.4.2_01\bin

See the attached images for environment setting and file explorer showing additional information. System settings not available for me to edit.

Thank you
EnvironmentSttings.bmp
Startup-bat.bmp
0
Comment
Question by:Mike Eghtebas
  • 6
  • 3
  • 3
12 Comments
 
LVL 47

Accepted Solution

by:
for_yan earned 400 total points
Comment Utility
you rather open dos command line ands go to the folder where your startup.bat is stitiing
and type

startup.bat in the commad line - you'll see at what point the eroor is happening and post it
0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
brb
0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
C:\Program Files\Apache Software Foundation\Tomcat 5.0\bin>startup.bat
Using CATALINA_BASE:   C:\Program Files\Apache Software Foundation\Tomcat 5.0\
Using CATALINA_HOME:   C:\Program Files\Apache Software Foundation\Tomcat 5.0\
Using CATALINA_TMPDIR: C:\Program Files\Apache Software Foundation\Tomcat 5.0\\t
emp
Using JAVA_HOME:       C:\j2sdk1.4.2_01
C:\Program Files\Apache Software Foundation\Tomcat 5.0\bin>

I guess it is runing ok then.

I will try to shut down and try http://localhost/8080 and then start up and do the same.

brb
0
 
LVL 27

Assisted Solution

by:rrz
rrz earned 100 total points
Comment Utility
For your convenience, I suggest that you right-click on the startup.bat file and select "Create Shortcut". Move that shortcut onto your desktop and click on it when you want to start Tomcat.
0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
shut down has one error:

C:\Program Files\Apache Software Foundation\Tomcat 5.0\bin>shutdown.bat
Using CATALINA_BASE:   C:\Program Files\Apache Software Foundation\Tomcat 5.0\
Using CATALINA_HOME:   C:\Program Files\Apache Software Foundation\Tomcat 5.0\
Using CATALINA_TMPDIR: C:\Program Files\Apache Software Foundation\Tomcat 5.0\\t
emp
Using JAVA_HOME:       C:\j2sdk1.4.2_01
Exception in thread "main" java.lang.NoClassDefFoundError: Files\Apache
C:\Program Files\Apache Software Foundation\Tomcat 5.0\bin>

Which is not an issue now.
0
 
LVL 27

Expert Comment

by:rrz
Comment Utility
eghtebas,  did that solution for your last question really work ?
Didn't you still get the error ?
CarBean cannot be resolved to a type
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 47

Expert Comment

by:for_yan
Comment Utility
So it is working fine ?
0
 
LVL 27

Expert Comment

by:rrz
Comment Utility
If you don't like my first suggestion above here, then you can do it your way by using quotes around the path. The spaces are the problem.  
C:\>"Program Files\Apache Software Foundation\Tomcat 5.0\bin\startup.bat"

Open in new window

0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
All I needed was some setup changes our it applied and it is working now.
0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
I will close the question this evening with additional information.
0
 
LVL 47

Expert Comment

by:for_yan
Comment Utility
Good, it works for you.
0
 
LVL 33

Author Comment

by:Mike Eghtebas
Comment Utility
To all,

In fact startup.bat or shutdown.bat were not my problem. The issue was I couldn't run some jsp file typed directly from a book.

In order for me to figure this out (suspecting some environment variables are not correctly set up) I was checking startup.bat or shutdown.bat to see if they work or not. This was to gather evidences what works and what doesn't work.

Lastly, IT department were involved and did some changes to the system path (details not revealed to me). Finally my jsp files work and that is what mostly mattered to me.

 rrz@871311,
re> For your convenience, I suggest that you right-click on the startup.bat file and select "Create Shortcut". Move that shortcut onto your desktop and click on it when you want to start Tomcat.

This is a fine idea and I appreciate for sharing this. But it is a side issue.

Regards,

Mike
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now