-
7th June 2004, 01:06 PM
#1
Need help with apache+tomcat.(urgent)
hello
5 days ago i managed to setup apache
and it worked. soon after i tried to setup tomcat and although i started i couldn t reach the page
localhost:8080. maybe because of the firewall.
so i said i should install a connector. i picked up jk1.2.5. i installed it , i run the configuration script but after "make" i got this:
Making all in common
make[1]: Entering directory `/usr/local/src/jakarta-tomcat-connectors-jk-1.2.5-src/jk/native/common'
/bin/sh /usr/lib/apr/build/libtool --silent --mode=compile gcc -I/usr/include/httpd -g -O2 -O2 -g -pipe -march=i386 -mcpu=i686 -pthread -DHAVE_APR -g -O2 -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -I /usr/java/j2sdk1.4.2_04/include -I /usr/java/j2sdk1.4.2_04/include/ -c jk_connect.c
jk_connect.c:99:28: apr_network_io.h: No such file or directory
jk_connect.c:100:23: apr_errno.h: No such file or directory
jk_connect.c:101:25: apr_general.h: No such file or directory
jk_connect.c: In function `jk_resolve':
jk_connect.c:140: error: `apr_pool_t' undeclared (first use in this function)
jk_connect.c:140: error: (Each undeclared identifier is reported only once
jk_connect.c:140: error: for each function it appears in.)
jk_connect.c:140: error: `context' undeclared (first use in this function)
jk_connect.c:141: error: `apr_sockaddr_t' undeclared (first use in this function)
jk_connect.c:141: error: `remote_sa' undeclared (first use in this function)
jk_connect.c:145: error: `APR_SUCCESS' undeclared (first use in this function)
jk_connect.c:148: error: `APR_UNSPEC' undeclared (first use in this function)
jk_connect.c:148: error: `apr_port_t' undeclared (first use in this function)
jk_connect.c:148: error: syntax error before "port"
make[1]: *** [jk_connect.lo] Error 1
make[1]: Leaving directory `/usr/local/src/jakarta-tomcat-connectors-jk-1.2.5-src/jk/native/common'
make: *** [all-recursive] Error 1
as it seems tha epr header files are not seen.
i am desperate as i have to implement a project with java servlets.
thanks....immediate help needed
-
7th June 2004, 06:51 PM
#2
if you have a FC1, jakarta site provide a package with mod_jk 2 ...
For FC2; on the 4th CD, you have the RPM for mod_jk ...
To use Tomcat you havve to set variable :
TOMCAT_HOME=path_of_tomcat
JAVA_HOME=path_of_jdk
For tomcat, you have to use port 8080 and 80 for apache.
With tomcat + apache, you can see the welcome page of apache with http://localhost
hope it helps,
deuch
-
8th June 2004, 01:47 PM
#3
CATALINA_HOME=path to tomcat
You should probably start using mod_jk2 instead of jk these days. mod_jk2 is better suited for multithreaded servers like apache2 and was made to replace mod_jk. It's just too hard to get people to figure out and use an almost undocumented configuration. (or step away from the autoconfig patch that was made for mod_jk)
Tomcat doesn't need to be running on 8080, 8080 is irrelivent to the working with the JK/AJP13 protocol that runs on 8009. mod_jk and mod_jk2 only connect using this but even they can be configured to use whatever port you choose. 8009 is just default. 8080 is just the connector you use if you want to reach tomcat directly via http.
Like duech said, get the mod_jk2 DSO module from the FC2 build... There shouldn't be any harm in that. But it's also very easy to build if you feel like doing so. Then you just need to set your workers2.properties file to pass off whatever uri's tomcat container should process instead of apache. You'll also need to configure apache's httpd.conf to forward all /*.jsp requests to the JK/AJP13 connector
Here's a relativly new compilation/additions/updates of howto's I did for my brother in law... Not complete but should get you going initially.
http://mikepalmer.net/howto/
-
10th June 2004, 05:15 AM
#4
what was your ./configure command?
i have to "./configure with-apxs=/usr/local/apache/bin/apxs" to make.
-
11th June 2004, 06:27 PM
#5
omg!
thx for the link, this rescued me from a 2-week-struggle, editing config-files, starting and stopping tomcats and apaches..
it works, apache and tomcat talk to each other
Similar Threads
-
By demck85 in forum Servers & Networking
Replies: 0
Last Post: 21st January 2007, 04:33 PM
-
By nayeemmz in forum Using Fedora
Replies: 2
Last Post: 23rd June 2006, 04:37 PM
-
By LeAkEd in forum Guides & Solutions (Not For Questions)
Replies: 2
Last Post: 27th June 2005, 09:55 AM
-
By RaCarter in forum Servers & Networking
Replies: 2
Last Post: 20th September 2004, 09:13 AM
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
[[template footer(Guest)]]