Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java Open Source > Apache Tomcat
|
Apache Tomcat General discussion of the Apache Tomcat servlet container. For discussions specific to the Professional Apache Tomcat book, please see the book discussion forum for that book.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Apache Tomcat section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 19th, 2005, 07:17 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default jakarta-tomcat-5, Apache, Windows

I need above configuration ( Windows 2000 professional ); but I can't run JSP, though I run ( their demo/examples ) servlets.

Can some-one point out what configuration, i am failing ? Also I need to run JSP/Servlets from /wwwroot; what need I do to let Apache pass .jsp to tomcat, and tomcat to run my .jsp files in /wwwroot.

Any fruitful help'll b appreciated.

Quote:
quote:What is catalina , by the way. [I'm new2java ! ]

__________________
`~@#\^%&*/\.<.\/-|+|_!:;..=?>
PHP, SEO | anshul shrivastava | mediasworks.org | FB
 
Old April 19th, 2005, 03:52 PM
Friend of Wrox
 
Join Date: Jul 2004
Posts: 204
Thanks: 0
Thanked 0 Times in 0 Posts
Default

To get jsp's to run you need the same directory structure that exists under webapps for the jsp examples. There are a number of folders including some xml files. The easiest way is to copy the existing folder, then rename it. When you stop and restart tomcat the folder should be picked up automatically as long as the directory structure and web.xml are in place.

In order to use tomcat with apache you will need to install the j2k connector (I think thats the name, havent looked at it for a while), I think the jakarta tomcat home page mentions this.

 
Old April 25th, 2005, 06:53 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default

Thank u4 the enlightenment.

I've unzipped jakarta-tomcat to D:\jakarta-tomcat\binjdk resides at D:\Program Files\Java\jdk1.5.0jre resides at D:\Program Files\Java\jre1.5.0OS is C:\Windows\ ( I'm using Windows 2003 Standard Edition )
Apache is running from D:\Program Files\Apache Group\Apache2\bin\apache.exe

Aapche ( mod_rewrite enabled )/PHP/MySQL/Perl is working fine.

But I've problems with Tomcat.
When I call startup.bat of Tomcat from command prompt, command prompt instantly! closes without any message.

http://localhost:8080/ is showing nothing.

Please, guide me to set .jsp for Apache as I set .php
I call PHP files from C:\Inetpub\wwwroot\ on port 80.
Can I call .jsp from same directory, though at port 8080.
( I assume, Java Application Server requires separate port lieu http://localhost/ ; Apache is already using http://localhost/ )

Help me, do this, please, please

Quote:
quote:What is catalina, by the way ?
( haven't seen it in previous Tomcat versions )
 
Old April 26th, 2005, 07:47 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default

Hmm, I got tomcat to run .jsp on http://localhost:8080/~
But, I can't login to http://localhost:8080/admin/frameset.jsp
What's the password ?
Also, can some1 tell me clearly, how can I connect it to Apache.
How2deal with j2k connector -n- mod_jserv ?
No idea
Quote:
quote:What is catalina, by the way ?
( haven't seen it in previous Tomcat versions )
Code:
Hope, some1 iz living there4this thread !!
Please reply. Please reply. Some1 of u might've worked it, already, I think.

 
Old April 26th, 2005, 05:26 PM
Friend of Wrox
 
Join Date: Jul 2004
Posts: 204
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You need to create the same directory structure used for the jsp-examples under webapps folder for your site. You need the files such as web.xml also.

I coppied the jsp-examples folder, renamed it and deleted the old jsp's and other stuff, restarted tomcat, with the structure and web.xml tomcat found the application.

you could leave some of the examples in place for the first run to check they are working.

Reference apache, you need a connector, the jk2 connector I think, pretty sure this can be downloaded from jakarta site.

 
Old April 28th, 2005, 03:42 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default

login for http://localhost:8080/admin/ can be created by fit -ing

<?xml version='1.0' encoding='utf-8'?>
<tomcat-users>
    <role rolename="admin"/>
    <user username="admin" password="admin" roles="admin"/>
</tomcat-users>

in file ~\jakarta-tomcat-5\conf\tomcat-users.xml

Still've problem with integrating /wwwroot, Apache, MySQL

 
Old May 4th, 2005, 01:38 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default

Ok, I'm now trying my first .jsp script.
I've placed
Code:
<%= application.getServerInfo() %>
in 1.jsp in folder c:\jakarta-tomcat-5\webapps\root
http://localhost:8080/1.jsp worked. Very good. Now, I wanna ask, what is WEB-INF folder in each of jsp aplication?
What is the alliance b/w JSP-n-XML? ( I don't use/need any XML in PHP! ) Please, answer these ( stupid ) questions2me; I'm learning 'abcd' of JSP.

I've downloaded blogroll Web log from SourceForge; I want2first install it; then customize it; then upload it live!
So I can say, I've done my first project in JSP ( with individualistic efforts plus help with P2P users! And I hope2get a nice job, then! ).
Quote:
quote:What is ANT? I'm curious what has ANT -n- XML has to do with JSP!
 
Old May 8th, 2005, 03:00 PM
Friend of Wrox
 
Join Date: Jul 2004
Posts: 204
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Bit late replying to this, in order to use startup.bat in windows you need to setup the classpath for java, alternatively you can add it in the startup.bat file, something like:

@echo off
set JAVA_HOME=c:\j2sdk1.4.2_01

Edit startup.bat with notepad.

Do the same for shutdown.bat






Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache Tomcat atul.kumar@drydentech.com Apache Tomcat 3 April 19th, 2006 07:24 AM
I've downloaded Jakarta-tomcat-5.5.9, now Im stuck xena BOOK: Professional Apache Tomcat 0 October 13th, 2005 08:05 AM
JWS Axis Tomcat (posted to Apache Tomcat too) rushman Servlets 0 April 15th, 2005 09:32 AM
Tomcat-Apache Integration puneetgt Apache Tomcat 0 January 30th, 2005 07:36 PM
Apache Tomcat/4.1.2 and Windows 2K Advanced server billyducs Apache Tomcat 4 November 7th, 2003 11:33 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.