Link to home
Start Free TrialLog in
Avatar of zania22
zania22

asked on

Configuring Tomcat

Though I have assigned a port of 8100 for Tomcat, i cannot get the welcome screen when I do http://localhost:8100. Does it matter that I have Apache web server running, but its on port 80.
Avatar of ramazanyich
ramazanyich
Flag of Belgium image

Apache server on port 80 doesn't have any interference with Tomcat on port 8100.
Check first Tomcat log files. Could you send also error messages in that files if they exists.
Check httpd.conf of Apache server: it shouldn't contain port 8100
Avatar of zania22
zania22

ASKER

Information found in jakarta_service_20040907:
[2004-09-07 15:13:00] [info] Service Tomcat5 name Apache Tomcat
[2004-09-07 15:13:01] [info] Service Tomcat5 installed
[2004-09-07 15:13:01] [info] Procrun finished.
[2004-09-07 15:14:05] [info] Updating service...
[2004-09-07 15:14:06] [info] Service Tomcat5 updated
[2004-09-07 15:14:06] [info] Update service finished.
[2004-09-07 15:14:06] [info] Procrun finished.
[2004-09-07 15:14:06] [info] Updating service...
[2004-09-07 15:14:06] [info] Service Tomcat5 updated
[2004-09-07 15:14:06] [info] Update service finished.
[2004-09-07 15:14:06] [info] Procrun finished.

Information found ing jakarta_service_20040908:
NONE

Files stdout and stderr are empty as well.
I'm wondering if its my version of Tomcat, 5.0? httpd.conf does not contain port 8100.
ASKER CERTIFIED SOLUTION
Avatar of ronan_40060
ronan_40060
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of zania22

ASKER

Hey,
     I think it was the compatibiity of the Tomcat5.0 i had the java1.4.2 version. Tomcat 5.0 needs the java 5.0 version. I uninstalled it, then intalled a  tomcat 4.1 version and everything worked smoothly. Now however, I'm having problems with my form. I have my action parameter invoking a servlet. the action button should say..
<form method="post" action="http://mydomain:8080/Production/servlet/editorServlet">
Where my file structure is:
C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\classes

I have the editorServlet.class and .java in the classes folder. Its not working.
shouldn't it be :
http://mydomain:8080/Production/editorServlet

did you define that servlet in web.xml in C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF ?
Could you send your web.xml ?

pls check it out

for in context
it shud be like
<Context path="/Production"
    docBase="webapps/Production"
    debug="0"
    reloadable="true">
</Context>

-----------------------------------------------------------------------------------------------------------------------------------------------
You need to  have a directory structure like following

C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\

C:\Program Files\Apache Group\Tomcat4.1\webapps\Production\WEB-INF\
C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\classes
C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\lib
C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\web.xml

And you should put your test.jsp in:
C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\


TOMCAT_HOME should refer to C:\Program Files\Apache Group\Tomcat 4.1\ and is used by the JDK to run tomcat.


You should have a url like: http://localhost:8080/Production/editorServlet

----------------------------------------------------------------------------------------------------------------------------------------------
and for classpath
Tomcat\webapps\ROOT\WEB-INF\classes\ to your classpath.
-------------------------------------------------------------------------------------------------------------------------------------------

let me know how it goes

A bientôt
Ronan
Avatar of zania22

ASKER

There were 2 web.xml files that came with Tomcat. One in
C:\Program Files\Apache Group\Tomcat 4.1\webapps\ROOT\WEB-INF
and another in
C:\Program Files\Apache Group\Tomcat 4.1\conf
Which should I copy and add
<Context path="/Production"
    docBase="webapps/Production"
    debug="0"
    reloadable="true">
</Context>

Avatar of zania22

ASKER

Also, my .class and .java files should be in the Production/classes folder? and not just Production?
You should modify web.xml in C:\Program Files\Apache Group\Tomcat 4.1\conf
and put .class file into webapps/Production/WEB-INF/classes
yes you need to modify the web.xml in  C:\Program Files\Apache Group\Tomcat 4.1\conf
Let us know
Good Luck
Ronan
Avatar of zania22

ASKER

I am getting the following error...

HTTP Status 404 - /Production/editorServlet

--------------------------------------------------------------------------------

type Status report

message /Production/editorServlet

description The requested resource (/Production/editorServlet) is not available.


--------------------------------------------------------------------------------

Apache Tomcat/4.1.30

******************************************************
Here are the facts
1. Environment Variables:
(System)
TOMCAT_HOME=C:\Program Files\Apache Group\Tomcat 4.1\
JAVA_HOME=C:\j2sdk1.4.2_05
CLASSPATH=C:\Program Files\Apache Group\Tomcat 4.1\common\lib\servlet.jar;C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\lib\servlet.jar
(User)
PATH=C:\Program Files\SSH Communications Security\SSH Secure Shell;C:\j2sdk1.4.2_05\bin;C:\Program Files\Apache Group\Tomcat 4.1\webapps\Production\WEB-INF\lib

2. Here is are xml files in conf
http://www.uvm.edu/~nspence/web.xml
http://www.uvm.edu/~nspence/server.xml

3. My file structure and url for the html for are correct.





Avatar of zania22

ASKER

Should I uncomment this out in web.xml?

<servlet-mapping>
        <servlet-name>invoker</servlet-name>
        <url-pattern>/servlet/*</url-pattern>
    </servlet-mapping>
hello Zania

Change web.xml in the conf folder
Uncomment
  <!-- The mapping for the invoker servlet -->
    <servlet-mapping>
        <servlet-name>invoker</servlet-name>
        <url-pattern>/servlet/*</url-pattern>
    </servlet-mapping>
And it will work.
Hello Zania
howz the overall process going on?
let us know
ronan
Periwinkle
The question has been answered with the best possible means. The user did not come back in spite of providing her all help. The points should be split accordingly.
Thank you
Ronan
Avatar of zania22

ASKER

None of the experts suggestions worked. I uninstalled tomcat and re-installed and didn't do anything and it worked
I think the question shud have given grade B or C the last .
All provious questions on Tomcat and Apache were solved with the help of he links I provided .
The Asker failed to come back after 9/10/2004
I think the question shud be given graded B Or C atleast
Regards
Ronan