Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Struts - A MVC web framework
Tomcat - JSP/Servlet container
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
JSP - A mailing list about Java Server Pages specification and reference
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
jk2 and ip-based vhosts

jk2 and ip-based vhosts

2004-01-27       - By Jim Hopp

 Back
Reply:     1     2     3  

I'm attempting to set up apache 2.0 and jk2 to use IP-based virtual
hosts, with no success.  I'd love it if someone on the list could point
out what I'm doing wrong (or point me to some doc that shows how to do
this - I've had no luck googling).

I've got apache up and running on a machine with two IP addresses.  I'd
like to run two tomcat instances, with exactly the same URI mapping, one
for each IP address.  The problem is that jk2 doesn't appear to take the
IP address of the request into account - it simply routes the request to
the JkUriSet defined last in the httpd.conf file.

Google searches show examples of this working for jk, but I cannot find
any examples of this for jk2.  If I can't figure this out I may have to
go back to jk.

Below are my jk2.conf, workers2.properties, and ssl.conf (which is
included into httpd.conf) files.

I'm running Apache 2.0.45, Tomcat 4.1.24, and jk2 from
jakarta-tomcat-connectors-4 (See http://ors-4.ora-code.com).1.24-src on RedHat 9.

jk2.conf:
JkOptions -ForwardKeySize -ForwardDirectories -ForwardURICompat
+ForwardURICompatUnparsed
JkWorkersFile conf/workers2.properties
JkLogFile /var/log/httpd/jk2.log
JkLogLevel debug
JkLogStampFormat "[%d/%b/%Y %H:%M:%S] "
# JkRequestLogFormat set the request format
JkRequestLogFormat "%w %V %T"

workers2.properties:
[logger]
level=DEBUG

[shm:]
info=Scoreboard.  Required for reconfig info and status
file=/var/log/httpd/jk2.shm
size=1000000
debug=0
disabled=0

[workerEnv:]
info=Global Server options
timing=0
debug=1

[channel.socket:68.166.222.75:8019]
info=Ajp13 forwarding over socket for nywdev
debug=1
host=68.166.222.75
tomcatId=dev1:8019

[channel.socket:68.166.222.77:8029]
info=Ajp13 forwarding over socket for nywdev2
debug=1
host=68.166.222.77
tomcatId=dev2:8029

[status:]
info=Status worker, displays runtime info

ssl.conf vhost defns:

<VirtualHost 68.166.222.77:443>
TransferLog /var/log/httpd/dev.access_log

SSLEngine on
SSLCipherSuite ALL:!ADH:!EXP56:RC4+RSA:+HIGH:!SSLv2
SSLCertificateFile /usr/local/etc/httpd/conf/httpd.crt
SSLCertificateKeyFile /usr/local/etc/httpd/conf/httpd.key

SetEnvIf User-Agent ".*MSIE.*" \
         nokeepalive ssl-unclean-shutdown \
         downgrade-1 (See http://ade-1.ora-code.com).0 force-response-1 (See http://nse-1.ora-code.com).0

CustomLog /var/log/httpd/ui.ssl_request_log \
          "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"

<Directory />
  Order Deny,Allow
  Deny from All
</Directory>

<Location "/jkstatus/*">
  SSLRequireSSL
  Order Allow,Deny
  Allow from All
  JkUriSet worker status:
</Location>

<Location />
  SSLRequireSSL
  Order Allow,Deny
  Allow from All
  JkUriSet worker ajp13:68.166.222.77:8029
</Location>

</VirtualHost>

<VirtualHost 68.166.222.75:443>
TransferLog /var/log/httpd/ui.access_log

SSLEngine on
SSLCipherSuite ALL:!ADH:!EXP56:RC4+RSA:+HIGH:!SSLv2
SSLCertificateFile /usr/local/etc/httpd/conf/httpd.crt
SSLCertificateKeyFile /usr/local/etc/httpd/conf/httpd.key

SetEnvIf User-Agent ".*MSIE.*" \
         nokeepalive ssl-unclean-shutdown \
         downgrade-1 (See http://ade-1.ora-code.com).0 force-response-1 (See http://nse-1.ora-code.com).0

CustomLog /var/log/httpd/ui.ssl_request_log \
          "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"

<Directory />
  Order Deny,Allow
  Deny from All
</Directory>

<Location "/jkstatus/*">
  SSLRequireSSL
  Order Allow,Deny
  Allow from All
  JkUriSet worker status:
</Location>

<Location />
  SSLRequireSSL
  Order Allow,Deny
  Allow from All
  JkUriSet worker ajp13:68.166.222.75:8019
</Location>

</VirtualHost>







-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)




©2008 junlu.com - Jax Systems, LLC, U.S.A.