Solved

Apache httpd on linux --- "make install" installs apache under /usr/local/apache2. where can we modify the default installation path?

Posted on 2011-03-03
6
555 Views
Last Modified: 2012-05-11
Hello everybody, I am new to Apache. I was tryinng to install apache on Linux, when i faced a challenge. I tried "make install" and it was trying to install apache under /usr/local/apache2. But i want to change this default installation path. I want to install some where else. Where can I change it. Please help me!!!!
0
Comment
Question by:Raz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 2

Accepted Solution

by:
Adjroth earned 500 total points
ID: 35024991
You'll need to configure it using "./configure" first.

Example:
./configure --prefix=/path/to/apache
make install

Here are two links to help you out:
http://httpd.apache.org/docs/2.0/install.html
http://httpd.apache.org/docs/2.0/programs/configure.html#installationdirectories
0
 
LVL 35

Expert Comment

by:torimar
ID: 35024998
In order to install a program to another than its default directory you would have to modify the 'make' file that comes with it.
The section that deals with the installation target will be marked by the variable "$(NORMAL_INSTALL)". Underneath, you will most likely find another variable called "$(DESTDIR)" or similar the definition of which will have to be altered in order to change the destination folder.

But this is not recommended at all.
In a program/service as complex as Apache there is no end to things that could or will go wrong if you meddle with the make-file - unless you really know what you are doing.

It is not even recommended to install Apache manually. Install it via your system's package manager (apt-get, aptitude, yum, pacman, zypper, yast etc.): this will make sure you install the version from your distros repository, which will be maintained and updated automatically when you update your system.
For security reasons, in a web application as critical as Apache, it is most important to make sure it is always up-to-date and all security fixes are applied immediately.
0
 

Author Comment

by:Raz
ID: 35025453
I have untarred httpd-2.2.17.tar. Executed following commands under httpd-2.2.17
./configure
make
make install (here is my problem)

Where do I find the make file?

I see below three files under httpd-2.2.17

Makefile
Makefile.in
Makefile.win

But there are no entries -  $(NORMAL_INSTALL) , $(DESTDIR)

Here are the contents of my httpd-2.2.17 directory.

$ pwd
/apps/elsdev/httpd-2.2.17
$ ls
ABOUT_APACHE  BuildAll.dsp  CHANGES        config.status  emacs-style  include         libhttpd.dsp  Makefile.win  modules.o      README            server   VERSIONING
acinclude.m4  BuildBin.dsp  config.layout  configure      httpd        INSTALL         LICENSE       modules       NOTICE         README.platforms  srclib
Apache.dsw    buildconf     config.log     configure.in   httpd.dsp    InstallBin.dsp  Makefile      modules.c     NWGNUmakefile  README-win32.txt  support
build         buildmark.o   config.nice    docs           httpd.spec   LAYOUT          Makefile.in   modules.lo    os             ROADMAP           test
0
Don't Miss ATEN at InfoComm 2017!

Visit booth #2167 to see the  new ATEN VM3200 32 x 32 Modular Matrix Switch. Other highlights include the VE8950 4K HDMI Over IP Extender, VS1912 12-Port DP Video Wall Media Player  and VK2100 ATEN Control System. Register now with Free Pass Code ATEN288!

 
LVL 35

Expert Comment

by:torimar
ID: 35025496
Did you try the solution suggested by Adjroth?

Since Apache seems to have the install dir as a configure option, that appears to be the easiest and most normal way to go.
Check the second link posted by Adjroth.
0
 

Author Comment

by:Raz
ID: 35025704
Sorry, I overlooked the links provided by Adjroth. They solved my problem. Thanks a lot Adjroth!!!!!

Thank you too torimar.
0
 

Author Closing Comment

by:Raz
ID: 35025916
Great!!! thank you
0

Featured Post

Why You Need a DevOps Toolchain

IT needs to deliver services with more agility and velocity. IT must roll out application features and innovations faster to keep up with customer demands, which is where a DevOps toolchain steps in. View the infographic to see why you need a DevOps toolchain.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Solr 4.0 it is possible to atomically (or partially) update individual fields in a document. This article will show the operations possible for atomic updating as well as setting up your Solr instance to be able to perform the actions. One major …
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question