Tuesday, December 13, 2011

Changing the Apache Installation directory in Linux

I am sure there are numerous posts online on how to install Apache in Linux Systems. Almost every post has the detailed steps listed out on how to go about. The basic steps are ./configure, make and make install. But what if there is already a different version of Apache installed in the default location. Then your installation goes for a Toss. Next the question arises "How to install Apache in a different location?". I was in a similar situation sometime ago. I searched online for answers. Almost all posts were inclined towards installation of Apache on Linux but none of them were concentrated on how one can change default installation directory of Apache. I opened the Apache Documentation and then found the solution. So I thought I will write a simple post on how to change the default installation directory so that it will save the user's time which is required to hunt down the solution in Apache documentation.

Well.. this is extremely simple. After downloading the tar.gz file from http://httpd.apache.org/download.cgi#apache22 location, unzip the file using tar -xvf <filename>.tar.gz command. Go inside the unzipped directory and type ./configure --prefix=<directory where apache should be installed>. For example, if you want to install Apache in the etc folder then the command will be ./configure --prefix=/etc/apache2 where Apache will be installed in the above location instead of the usual one. The remaining steps are the same. More details can be found by using the help command ie: ./configure --help.

Hope this post was helpful for some newbies who have started playing around with Apache.










13 comments:

  1. it was really a nice article and i was really impressed by reading this
    article We are also giving Linux Course Online Training.the Linux-
    -Online-Training
    is the one of the best Online Training institute.

    ReplyDelete
  2. Nicely explained. Here you described the well written article from your in-depth knowledge. Truly impressive and nice information

    Java Training in Chennai Core Java Training in Chennai Core Java Training in Chennai

    Java Online Training Java Online Training JavaEE Training in Chennai Java EE Training in Chennai

    ReplyDelete
  3. Smilearrow Find best products values got thousands of online top most bought items key points, rankings, price, photos lot of cool stuff to get from

    ReplyDelete
  4. In 2019, Adidas and Under Armour took most of the places in top 10. The Best Basketball Shoes doesn’t only depend on the shoe but also on the player. Be tricky enough in choosing your best fit.

    ReplyDelete
  5. Shop for high quality Best clothes steamer, Steamer for Clothes, garment steamer, Fabric Steamer All kinds of Steam Cleaner on Turbo Steam at best prices.

    ReplyDelete
  6. Steamer for Clothes that can get rid of all wrinkles on a matter of seconds, but use whatever you want to keep them hang.

    ReplyDelete
  7. Clothes Steamer Steamer for Clothes Garment Steamer U.S.A Turbo-Steam Shop for high quality Best clothes steamer, Steamer for Clothes, garment steamer, Fabric Steamer All kinds of Steam Cleaner on Turbo Steam at best prices

    ReplyDelete
  8. Fabric Steamer is a powerful, yet portable, fabric and clothes steamer for all of your steaming needs. Our Turbo Steam takes only 45 seconds to heat up and to start generating steam and its steam delivery system evenly distributes steam across fabrics to remove even the worst wrinkles.

    ReplyDelete
  9. Best Clothes Steamer for all of your steaming needs as it easily distributes steam across the fabric to remove worst wrinkles.

    ReplyDelete
  10. How to Use a Clothes Steamer A garment steamer is a great way to remove wrinkles from clothes. Steamers work by heating water until it becomes steam.

    ReplyDelete