Copy your current Apache files to another folder and modify the httpd.conf file. Change two things:
ServerRoot: give the path of the new folder where you have copied your apache files.
Listen: Give a new port number other than 80. It will be better if you give a port number larger than 1024.
Make sure you have not set the environment path for httpd.exe. if you have just remove it.
Stop any running Apache service if it is running.
Now in the command prompt navigate to the bin folder of new server. then type the following command.
httpd.exe -k install -n "New Apache" -f "C:/path/to/httpd.conf"
(Of the new server).
Now you can restart the service of your Apache.
Once you execute this command successfully, you'll find a new service named "New Apache" in services.msc. Start that service and in browser try to run the server with the new port number that you have given in the httpd.conf file of the new server.
Mostly that should work. But in case it doesn't execute the following command
httpd.exe -k config -n "New Apache" -f "C:\path\to\httpd.conf
- Hits: 3053