• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Rob Spoor
  • Henry Wong
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Carey Brown
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh
  • Jj Roberts

Help setting jforum and Apache->Tomcat connector

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello all,
I have a problem while I am trying to run jforum and connect apache-tomcat with mod_jk connector. When I am typing http://localhost:8080/jforum - everything is just fine. But I want to access the forum with forum.mycompany.com. Before explain my conf files I will say that I am using Suse Linux Enterprise Server. I have put jforum in /srv/www/tomcat5/base/webapps. I have a virtual host defined in my apache and it looks like this:

<VirtualHost 10.0.11.51:80>
ServerAdmin webmaster@mycompany.com
ServerName forum.mycompany.com:8080
ServerAlias forum.mycompany.com
ErrorLog /var/log/apache2/forum.mycompany.com-error_log
CustomLog /var/log/apache2/forum.mycompany.com-access_log combined
HostnameLookups Off
UseCanonicalName Off
JkMount /jforum/* ajp13
</VirtualHost>

My jk.conf file is this:

<IfModule mod_jk.c>
JkWorkersFile /etc/tomcat5/base/workers.properties
JkLogFile /var/log/tomcat5/base/mod_jk.log
# Log level to be used by mod_jk
JkLogLevel error
# The following line makes apache aware of the location of
# the /jforum context
Alias /jforum "/srv/www/tomcat5/base/webapps/jforum"
<Directory "/srv/www/tomcat5/base/webapps/jforum">
Options Indexes FollowSymLinks
allow from all
</Directory>
# The following line makes apache aware of the location of
# the /servlets-examples context
Alias /servlets-examples "/srv/www/tomcat5/base/webapps/servlets-examples"
<Directory "/srv/www/tomcat5/base/webapps/servlets-examples">
Options Indexes FollowSymLinks
allow from all
</Directory>
# The following line makes apache aware of the location of
# the /jsp-examples context
Alias /jsp-examples "/srv/www/tomcat5/base/webapps/jsp-examples"
<Directory "/srv/www/tomcat5/base/webapps/jsp-examples">
Options Indexes FollowSymLinks
allow from all
</Directory>
# The following line mounts all JSP files and the /servlet/ uri to tomcat
JkMount /servlets-examples/servlet/* ajp13
JkMount /jsp-examples/*.jsp ajp13
# The following line prohibits users from directly accessing WEB-INF
<Location "/jsp-examples/WEB-INF/">
AllowOverride None
deny from all
</Location>
<Location "/servlets-examples/WEB-INF/">
AllowOverride None
deny from all
</Location>
</IfModule>

In my workers.properties file I have pointed the Tomcat base directory and JAVA home directory.

I have a DNS and I have set it so forum.mycompany.com i going to the apache server. When i access forum.mycompany.com it came up a blank page with IT WORKS line. I have read a lot tutorials about connecting apache and tomcat but I have no success. Can you tell me what I am missing.
Thank you in advance.

[originally posted on jforum.net by chandler_kiril]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


In my workers.properties file I have pointed the Tomcat base directory and JAVA home directory.



Sounds like you're using an older workers properties file format (ajp12?). A current jk workers.properties file doesn't have directory names but looks like:



Note the ajp13 in the worker.list, default.worker, and worker.ajp13.* properties is just a name that is associated with the JkMount worker tag. E.g.:

JkMount /jforum/* ajp13 <- this is a name used in worker.list
[originally posted on jforum.net by monroe]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't know if I would be better off starting a new thread or hitchike onto this one? But here goes. I am trying to do a similar configuration but I am using MOD_PROXY_AJP.

Here is my VirtualHost settings:

<VirtualHost *:80>
ServerAdmin webmaster@blahblah.com
DocumentRoot /var/www/html
ServerName igames.blahblah.com
ServerAlias *.blahblah.com
<Location /jforum>
Options All
AuthName "iGames Forum Login"
AuthType Basic
AuthUserFile /var/www/.htpasswd
Require valid-user
</Location>
<Location /igamesWebApp>
Options All
AuthName "igamesWebApp Login"
AuthType Basic
AuthUserFile /var/www/.htpasswd
Require valid-user
</Location>
ProxyPass /jforum ajp://localhost:8009/jforum
ProxyPass /igamesWebApp ajp://localhost:8009/igamesWebApp
ErrorLog logs/igames.blahblah.com-error_log
CustomLog logs/igames.blahblah.com-access_log common
</VirtualHost>

I haven't modified the server.xml file as I wasn't really sure what I needed to modify.

I can connect to jforum just fine. However, I can never successfuly login unless I go to http://igames.blahblah.com:8400/jforum.

any help would be appreciated.
[originally posted on jforum.net by LichW]
 
Something must be done about this. Let's start by reading this tiny ad:
SKIP - a book about connecting industrious people with elderly land owners
https://coderanch.com/t/skip-book
reply
    Bookmark Topic Watch Topic
  • New Topic