Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Apache install

Status
Not open for further replies.

dbeez

Technical User
Aug 15, 2005
71
KR
Hi,

I am installing and uninstalling apache at the moment and I'm having a bit of trouble with the various ways my system installs the apache program. I'm not sure whether this is an apache1/apache2 issue, or an ubuntu linux issue or even whether it's just on the whim of the .deb maker who did the package.

What I consider to be a 'proper' install of apache puts it in

/usr/local/apache

where I can find my bin, conf folders etc...
It also throws the binary into

/etc/init.d/apache

so that I can manipulate it easily.
As well as providing a

httpd

in the path so that I can do a httpd -l

The other or 'improper' install of apache (IMO), seems to put apache in

/sbin

among other places, and seems to have folders strewn all over the place. I can't even find an

apxs

on my system. Both of them server from

/var/www

Is there something that I'm missing here ???
 
The way the package manager installs Apache is specific to it. If you want to specify the exact location, I suggest you compile from source.
 
When you try to put everything in one place, you will be opening a can of worms that will be hard to sort. Although the directory structure and locations vary between distros, there is a method to their madness. The executable is usually in a directory within your path. i.e. /usr/sbin. The scripts that are used to start, restart or kill the executable are in a directory where the system expects to find them. i.e. /etc/rc.d/init.d. The scripts call the executable and also specify the name and location of the configuration file. This is usually in the /conf sub-directory of what apache calls the "ServerRoot". This is where all apache's linked libraries and logs are kept. Actually, the are symlinks to where the systems expects them to be. The web space can be anywhere on the drive and is specific to each virtual host via the DocumentRoot directive in httpd.conf. It is general practice to put all vhosts in one location. Some distros put them under /var/www/ or under user's home directories. No matter how many times you install or even compile apache, you will need to edit a lot of files to make sure both the system and apache know where to find them.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top