Tomcat6 to Apache2.2 configuration for Windows

23 Jan

Step 1:

1)  Download and Install apache2.2 installer.

Download URL:

Step 2:

Download for windows and paste in modules folder.

C:\${apache installed path}\Apache2.2\modules

Step 3:

Create and mod_jk.conf  file inside conf folder

C:\ ${apache installed path}\Apache2.2\conf

Step 4:

Inside  just copy & paste, below mentioned content.(Replace your application insted of ${application name})

# Define worker ‘example’

worker.list=${application name}
# Set properties for worker ‘example’ (ajp13)
worker.${application name}.type=ajp13
worker.${application name}.host=localhost
worker.${application name}.port=8009

worker.${application name}.cachesize=10
worker.${application name}.cache_timeout=600
worker.${application name}.socket_keepalive=1
worker.${application name}.recycle_timeout=300

Step 5:

Inside mod_jk.conf just copy & paste, below mentioned content.

JkWorkersFile conf/

JkLogFile logs/mod_jk.log
JkLogLevel info
#JkExtractSSL On

Step 6:

Add below mentioned line inside the httpd.conf file(Just add the content in end of the file)

LoadModule jk_module modules/

#Include conf/mod_jk.conf
# Mod JK default settings
Include conf/mod_jk.conf

# Send ROOT app. to worker named app1
JkMount  /* ${application name}
JkUnMount  /images/* ${application name}
RewriteEngine On
RewriteRule ^/(images/.+);jsessionid=\w+$ /$1

#Deflate compression
SetOutputFilter DEFLATE
DeflateCompressionLevel 9

# Turn on Expires and set default to 0
ExpiresActive On
#ExpiresByType text/html M604800

# Set up caching on media files for 1 year (forever?)
ExpiresDefault A29030400

Step 7:

In the below mentioned file, Just remove # in front of the every line.(That mean you are un commenting the below mentioned .so modules )

LoadModule headers_module modules/
LoadModule deflate_module modules/
LoadModule cache_module modules/
LoadModule expires_module modules/
LoadModule ext_filter_module modules/
LoadModule rewrite_module modules/

Step 8:

Just start apache

Leave a comment

Posted by on January 23, 2012 in Apache, Installations


Tags: , ,

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: