Wamp wont use Apache but IIS instead ? - apache

I just installed the WAMP service The wamp page
The problem I am having is that, when I try running the local host, or the phpmyadmin it runs it automatically with my IIS7 server. I did stooped the IIS server from running, but then it says that the page it could not be found?
How to I prevent the IIS from starting on the start up, since I don't really use it?
How do I make the Apache my default server or something like that?

On each port only one server can listen to incoming requests. Http uses port 80 by default and it seems like IIS is configured to listen on that port on your machine.
To change this you have to edit the binding settings of iis (in "Internet Information Services (IIS) Manager" -> click on Sites\"Default Web Site", then there should be a link "Bindings" on the right side of the screen). In apache you have to edit on of the config files: http://httpd.apache.org/docs/2.0/en/mod/mpm_common.html#listen and restart apache.
You can reach your other webserver (not listening on port 80) by explicitly specifying the port number in the address: e.g. http://localhost:85/phpmyadmin

Related

How to change default 80 port to my tomcat 8080 for my domain name

I am using tomcat on Linux centOs server. I want my java application is working fine on mydomain.com:8080. I want that my when some one hit the domain mydomain.com it automatically move to my java application.
Changin server.xml didm't worked for me. as i am also having apache2 on the server
I guess you have an apache server in port 80. I you do not want to remove apache and change directly the tomcat port ( see comments), you will need to redirect all traffic from port 80 to port 8080.
This can be done using tomcat connectors. They are plugins to connect web servers with Tomcat. When a HTTP request arrives, the plugin checks is it has to be redirected, connects to tomcat and returns the response to server
In the case of apache is needed to install mod_jk. In the link you can see the configuration

Using Apache server beside Windows' World Wide Web Publishing Service

I have an old site (oldsite.com) running via World Wide Web Publishing Service on a Windows Server 2003 server. I've just create a new site (newsite.com) using the same server but running through Apache. The old site with its service running on port 80 already so I had to config Apache using port 8080. The problem is now when I publish my new site, the url has to be newsite.com:8080. How can I config Apache so that it can contain no port, just newsite.com?
As far as I know from personal experience and research:
Due to the nature of DNS Records you cannot specify the domain to redirect to an IP address and a port.
If both servers are listening on the same port a request would not know which site to direct to.
As the default port the domain specifies is port 80, any other port must be specified for the request to go to the correct location.
Therefor you cannot have newsite.com redirect to the server IP on port 8080, as it can only be directed to the server IP with DNS records. The port must be specified in the URL if it is on a port other than 80.
Edit: I just found this post about using a reverse proxy to do something similar to what you have described. Take a look and see if it helps you.
You cannot have two services listening on the same port. You can change the old site to listen to another port, set apache to port 80, then use mod_proxy to enable the old site to be accessed from apache using virtualhost
I have just make it work. Although in IIS Manager, there was no website listening on 0.0.0.0:80 but I still had to delete this entry by httpcfg tool. After that Apache can start normally.

IIS server and Apache server

I am running Tomcat Apache server for solr and I my web interface is based on IIS. I was wondering if it is possible that I run both IIS and Tomcat server on the same machine and with each other.
run them on different ports and you should be good to go. you can access them through the ports as follows:
localhost:80/myIISSite or localhost/myIISSite (default http port)
localhost:8080/myApacheWebsite
Configuring apache to listen on specific ports
For IIS:
Open up IIS Manager.
Open the properties windows of Default Web Site.
Select the Web Site Tab.
Under web site identification, you can change the default 80 port or you can click on Advance tab and then can change the default 80 port.
Yes, buy they will have to use different ports. INstall one and start it on the standard ports (80 for http, 443 for https) then install and configure the other to start on another set of ports.

IIS and Apache (WAMP) running

How can we run IIS 6 and Apache (wamp) in same machine at same time?
IIS and Apache should have different port.
To change the port of Apache(WAMP)
Click on WAMP icon that you can see on your tray or other shortcut icons for wamp.
Look for the Apache and open the httpd.conf or if you know where it is stored.
Find the "80" then change
Listen 80 to Listen 8080
ServerName localhost:80 to ServerName localhost:8080
Note: You can change the port which you desired as long as it will not conflict with your other port. It is more safe and common if the port is at this range.
Then click on Restart All Services.
See here for more info.
If you prefer to change your IIS rather Apache, check on this IIS
Another thing to watch out for is the port used for VirtualHosts (443). In your Apache folder, in conf/extra there should be a file called http-vhosts.conf
You should change all instances of 443 to a different port.
Change:
Listen 443
NameVirtualHost 127.0.0.1:443
<VirtualHost 127.0.0.1:443>
Then you should be good to run both services.
In the WAMPSERVER 3.0.6 and above right Click WAMPSERVER icon and navigate to tools option.(only if its green color- i.e all services are running). It will list all the options for Apache and MySQL. Test the available port or if not click on 'Use a port other than 8080, it will give you a pop up box and you can enter the value and text the port.Image attached
Or like in my case, I wanted wamp to run on port :80 on a secondary ip on the same network card.
This allows me to use my main ip to run IIS on :80 and the secondary ip :80 apache.
How to get multiple IP's on same networkcard? stackoverflow alias IP
Browse to 'C:\wamp64\bin\apache\apache2.4.23\conf'
open httpd.conf
Look for Line ~72 Listen 0.0.0.0:80 and change this to the secondary ip (in my case 192.168.210.41:80).
I had to restart pc because IIS did not want to restart. Start IIS first, then Wamp.
Works!
You can run both server simultenously by changing port number of Apache or IIS.
A) How you can change Apache port number:
1) Open “httpd.conf” file located in folder “C:\wamp64\bin\apache\apache2.4.23\conf”. You can also open file directly from system try if your wamp is running.
2) Search for “listen” text in file and update the default port 80 to 8080.
3) Now Restart the WAMP server to make new port number effective.
4) Open the browser with url “http://localhost:8080/” wamp will show home page.
Reff: http://sforsuresh.in/iis-and-wamp-servers-on-the-same-system/
B) How you can change IIS port:
1) Go start and type IIS.
2) IIS Manager will open. click on “Default Web Site” on left hand side.
3) click on “bindings…” from the right side action section.
4) Popup will open with 80 port listed. select it and click the edit button.
5) Update the port and restart the server.Now try to access using browser.
Reff: http://sforsuresh.in/change-iis-port-windows/

Apache is listening on a different port, but how do I get it so I don't have to type in the port number?

I am running IIS and Apache HTTP Server side-by-side on my localhost machine, and Apache is listening on a different port (port 81). IIS is listening to port 80. However, I can only get to my virtual domains for Apache if I type in that port number. So for instance:
http://virtual.myvirtualdomain.com:81
http://virtual.myvirtualdomain2.com:81
How can I make it so Apache automatically knows it is port 81, and does not force me to type in the port number?
EDIT:
The answer appears to be that I need to redirect IIS to Apache. Can anyone provide clarification on how that is done with IIS 5.1?
It's not a matter of telling Apache, it's a matter of the browser knowing what to connect to. You're either going to have to have IIS redirect to Apache, or give up.
You have to type in the port number so your client knows where to connect to. This has nothing to do with the server.
On Unix systems you might be able to modify your /etc/services to list 81 as port for http. But that would effectively disable access to all websites that are located on port 80.
Alternatively you can configure your IIS on port 80 to locally proxy requests for the sites which are on apache. Then all clients would ask the IIS for a page, which would make a local connection to port 81.
I did some more research and it turns out that you can't redirect IIS 5.1 to Apache because that would require multiple Web sites (setup as redirects to the virtual hosts on Apache on port 81). This is because IIS 5.1 on Windows XP Pro can't do multiple Web sites (running at the same time without the scripting hack). Oh well.
How about you swap it? Make Apache listen on port 80, IIS on port 81 for whatever you need and have Apache redirect? Apache shouldn't be restricted to the same one-website per machine that IIS 5.1 is.
You can't. The 81 is telling your browser where to look for Apache.
You can't.
It's the job of your web client to specify the port, and until you do specify that port it won't even reach Apache.
What you could potentially do is have IIS also listen for the same HTTP/1.1 virtual hosts, and then arrange for it to issue a 302 Moved redirect to send your browser to the right port number.
Alternatively, run a second IP address on your machine, and bind IIS to the original IP address and Apache to the second. That way you don't need to use different ports at all.
There is no way to do exactly what you ask. About the only way would be to configure IIS -- for the virtual domains being served by IIS -- to forward to Apache on port 81. With this configuration, the client would not be aware that their requests were passing through IIS on their way to Apache. A little less efficient, but it would solve your needs.
When an url is typed, there is a certain port that the browser has to use to connect to the site. 80 is the default port that the server checks. If you need to connect to any other port via a browser, you would need to have the port number in the url. It is not apache that is forcing you to type 81, but rather your browser because it is set to use 80 as the port when a port number is not specified.
If you were to change apache's port to 80 and IIS port to 81, then you be able to connect to apache without the port number but you will need to use the port number when using the IIS webserver.
Not sure what the others idea is behind using apache to redirect to IIS. It sounds like to me that if you make an entry in httpd.conf of apache for IIS directory, then you be using apache to connect to the directory, not IIS.
You could set up a domain and have it connect to apache via port 81. That is one way to hide the port number (might be not true. I have never tried apache on port other than 80).