Saturday, June 18, 2011

Compiling tomcat connectors for Apache HTTP Server


Once you sure that Apache HTTP server is compiled and working fine, now it’s time to compile the tomcat connectors for load balancing. In this article we will see how we can compile the tomcat connectors like mod_jk.so ,mod_proxy and other connectors.

First download the tomcat connector’s source from Here.

Once you downloaded the source, follow the steps to compile the source

1. Extract the tar file using tar –xvf tomcat-connectors-1.2.31.src
2. Now enter the tomcat-connectors-1.2.31 directory cd tomcat-connectors-1.2.31
3. cd native
4. Now we need to compile tomcat connectors with using apxs available in rhel
(apxs is nothing but an apache extension tool which helps in building and installing extension modules for apache server)

./configure –with-apxs=/usr/sbin/apxs

If you configure apache server from source, then you can find the apxs available in /usr/local/apacche2/bin/apxs
If you have not configure from source and using a http version available in linux then find where the apxs is available, to do this use command

Whereis apxs

Which shows the locations where apxs is available?

5. make
6. Make install

Now once everything is compiled and installed, go and check the modules directory in apache server. We can find mod_jk, mod_proxy and other apache extensions available.

More Things to come….
Read More

Compile Apache HTTP Server From Source


Apache HTTP server plays an important role in hosting area. It not only allows providing static content support but also allows providing load balancing support. In this article we will see how we can compile apache from source and start server.

First download the Apache latest version source from Here.

Once you download the apache source, follow the steps to compile the source

1. Extract the tar file using tar –xvf http-2.0.64.
2. Now enter into the http-2-0-64 directory. cd http-2.0.64
3. Enter command. ./configure (a “.(dot)” before /)
4. Enter command make
5. Enter command make install
Once all steps are done completely, we can check the apache installed in location
/usr/local/apache2

In order to start apache, go to /usr/local/apache2/bin
Enter the command. ./apachectl start (a “.(dot)” before /)

Go to browser and enter http://localhost/ to see if it works

While compiling the source code, it may throws and error saying
No available c compilers found

Then just install compiles available in Linux Gcc,Gcc-c++ and their dependencies.

More Things to come …..
Read More