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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

multiple servers

Status
Not open for further replies.

drska

Programmer
May 21, 2004
14
HR
How is it doable to have two Apache servers on the same machine which is running under Win 2000 Professional??
Do I need to install whole additional apache or can it be done just by configuring it? They should be independent to eachother.
 
The default port address is 80, so you will need a configuration for a different port, ie the answer is yes, just config files have to be different.
 
/usr/local/apache2/bin/apachectl -f /usr/local/apache2/conf/httpd.conf

allows you to specify another configuration. Of course be careful of any overlaps in your systems which may cause problems.

 
cdlvj,
I'm avare of this, I also have few ports in use, but I don't want all the configuration to be every time started (loaded), and after working with it for a while, I won't be able to distingush my configuration from my friends' (since we'll be working with different db's).
So, does your solution involve some sort of this kind of making difference ( I'm kind'a new to apache)?
oh, I'm working under win2000.
 
First of all cdlvj was pointing out that you can have the same installation of apache and simply start two instances of it specifying different config files, while everything else can be the same.

Secondly, why do you think you need two versions of apache running?
 
Changing port isn't enough, cause after changing config for a while, I won't know what is mine and what is frends'.
But I don't know how to achieve to use different config files (in win2000)?
 
I don't see the problem. Keep two separate configuration files and you'll know which is which.

c:\apache\conf\mine.conf
c:\apache\conf\friend.conf

You don't need to install Apache twice, just run it twice if you need the instances to be "independent to eachother".

 
Under windows i dont think you can start two services at the same time you will more likely get a service is started already. That service if you look at the service instalation of that service it will be pointing to the default server that was installed and not the second service as the second service will not be installed as one is already installed.
What you need to do to get a secodn apache server up and running on windows is to change the name of the service from apache to somethign else
You can have any number of serivices installed but they all must be named something different
you can do this from the command line as such.

Not so hard really go to where you installed it or unzipped it what ever drive that will be. EG: C:\ or C:\Apache Group\Apache2\bin. Those are usually the two default locations, i prefer myself to put it on another partition of a drive or another drive completely. Now you have a real view of where you need to point the command prompt
In order for you to move from one place to another you need to change directory the command for that is cd. so at your shell prompt with in the command line window you will type cd then the exact path to the bin folder EG: >cd C:\ then click the enter key. If you have installed or unzipped the Apache Server on to another partition or drive you will need to do one more thing that is actually tell the command prompt to go to that drive you enter the second command as such EG:>d: that is if you did this on your d drive. Now that you are in your proper location to finally do the work that is needed to setup a Second Apache Server.

Really all you are going to do is rename the Second Apache Server something other then Apache. You can not just rename the file apache.exe, you have to tell the system how to recognize the difference.
In order for you to move from one place to another you need to change directory the command for that is cd. so at your shell prompt with in the command line window you will type cd then the exact path to the bin folder EG: >cd C:\ then click the enter key. If you have installed or unzipped the Apache Server on to another partition or drive you will need to do one more thing that is actually tell the command prompt to go to that drive you enter the second command as such EG:>d: that is if you did this on your d drive. Now that you are in your proper location to finally do the work that is needed to setup a Second Apache Server.

Really all you are going to do is rename the Second Apache Server something other then Apache. You can not just rename the file apache.exe, you have to tell the system how to recognize the difference.
In order for you to move from one place to another you need to change directory the command for that is cd. so at your shell prompt with in the command line window you will type cd then the exact path to the bin folder EG: >cd C:\ then click the enter key. If you have installed or unzipped the Apache Server on to another partition or drive you will need to do one more thing that is actually tell the command prompt to go to that drive you enter the second command as such EG:>d: that is if you did this on your d drive. Now that you are in your proper location to finally do the work that is needed to setup a Second Apache Server.

Really all you are going to do is rename the Second Apache Server something other then Apache. You can not just rename the file apache.exe, you have to tell the system how to recognize the difference.
In order for you to move from one place to another you need to change directory the command for that is cd. so at your shell prompt with in the command line window you will type cd then the exact path to the bin folder EG: >cd C:\ then click the enter key. If you have installed or unzipped the Apache Server on to another partition or drive you will need to do one more thing that is actually tell the command prompt to go to that drive you enter the second command as such EG:>d: that is if you did this on your d drive. Now that you are in your proper location to finally do the work that is needed to setup a Second Apache Server.

Really all you are going to do is rename the Second Apache Server something other then Apache. You can not just rename the file apache.exe, you have to tell the system how to recognize the difference.
In order for you to move from one place to another you need to change directory the command for that is cd. so at your shell prompt with in the command line window you will type cd then the exact path to the bin folder EG: >cd C:\ then click the enter key. If you have installed or unzipped the Apache Server on to another partition or drive you will need to do one more thing that is actually tell the command prompt to go to that drive you enter the second command as such EG:>d: that is if you did this on your d drive. Now that you are in your proper location to finally do the work that is needed to setup a Second Apache Server.
Just as if you where going to install a single server the command would be
EG:>Apache -k install -n "Apache"
To rename the serever you would type this.
EG:>Apache -k install -n "the name you want to call your server in between these quotes"
If you where going to install a ssl version server you would need to add a little bit more code to make it work. EG:>Apache -D SSL -k install -n "name of server" And that is all there is to it!

Never ever keep things in writing LOL
it will always come back to ya in some form or another LOL
 
On a side note if you want a different version of apache installed you can do that at anytime.
A second server with the same version must be labled something different.

Never ever keep things in writing LOL
it will always come back to ya in some form or another LOL
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top