I am a novice I do not know anything about port numbers and how to change them. While installing Xampp on my windows 8.1 it is showing Error in port that apache has to use. How can I resolve this port issue and which port number I should change it to
Please help me out
This is the error coming while running xampp
Open xamp, click on http.conf and search ServerName localhost
ServerName localhost:8181
I have set 8181 as my port, it will be 80 change it to 81 (since 80 is being used VMware in your case and it is used by skype too).
Reset the server after saving it..
This is a common issue. For an example Developers can run Java web applications on JBoss server and at the same time test PHP project on XAMMP server. To make both servers up and carry out developments, port numbers need to be changed. Following is the way for changing port number in XAMMP Server.
If the XAMPP server is running for the moment, stop XAMPP server.
Follow these steps to change the port number.
Open the file in following location.
[XAMPP Installation Folder]/apache/conf/httpd.conf
Open the httpd.conf file and search for the String:
Listen 80
This is the port number used by XAMMP.
Then search for the string ServerName and update the Port Number which you entered earlier for Listen
Now save and re-start XAMPP server.
Related
This is my Apache httpd.conf settings :
Listen 8012
ServerName localhost:8012
Every time I start Apache via XAMPP I see this message:
Status Check OK
Busy…
Apache Started [Port 80]
Anybody, please help me can I change any other settings ?
To answer the original question:
To change the XAMPP Apache server port here the procedure :
1. Choose a free port number
The default port used by Apache is 80.
Take a look to all your used ports with Netstat (integrated to XAMPP Control Panel).
Then you can see all used ports and here we see that the 80port is already used by System.
Choose a free port number (8012, for this exemple).
2. Edit the file "httpd.conf"
This file should be found in C:\xampp\apache\conf on Windows or in bin/apache for Linux.:
Listen 80
ServerName localhost:80
Replace them by:
Listen 8012
ServerName localhost:8012
Save the file.
Access to : http://localhost:8012 for check if it's work.
If not, you must to edit the http-ssl.conf file as explain in step 3 below. ↓
3. Edit the file "http-ssl.conf"
This file should be found in C:\xampp\apache\conf\extra on Windows or see this link for Linux.
Locate the following lines:
Listen 443
<VirtualHost _default_:443>
ServerName localhost:443
Replace them by with a other port number (8013 for this example) :
Listen 8013
<VirtualHost _default_:8013>
ServerName localhost:8013
Save the file.
Restart the Apache Server.
Access to : http://localhost:8012 for check if it's work.
4. Configure XAMPP Apache server settings
If your want to access localhost without specify the port number in the URL http://localhost instead of http://localhost:8012.
Open Xampp Control Panel
Go to Config ► Service and Port Settings ► Apache
Replace the Main Port and SSL Port values with those chosen (e.g. 8012 and 8013).
Save Service settings
Save Configuration of Control Panel
Restart the Apache Server
It should work now.
4.1. Web browser configuration
If this configuration isn't hiding port number in URL it's because your web browser is not configured for. See : Tools ► Options ► General ► Connection Settings... will allow you to choose different ports or change proxy settings.
4.2. For the rare cases of ultimate bad luck
If step 4 and Web browser configuration are not working for you the only way to do this is to change back to 80, or to install a listener on port 80 (like a proxy) that redirects all your traffic to port 8012.
To answer your problem :
If you still have this message in Control Panel Console :
Apache Started [Port 80]
Find location of xampp-control.exe file (probably in C:\xampp)
Create a file XAMPP.INI in that directory (so XAMPP.ini and xampp-control.exe are in the same directory)
Put following lines in the XAMPP.INI file:
[PORTS]
apache = 8012
Now , you will always get:
Apache started [Port 8012]
Please note that, this is for display purpose only.
It has no relation with your httpd.conf.
The best solution is to reconfigure the XAMPP Apache server to listen and use different port numbers. Here is how you do it:
1) First, you need to open the Apache “httpd.conf” file and configure it to use/listen on a new port no. To open httpd.conf file, click the “Config” button next to Apache “Start” and “Admin” buttons. In the popup menu that opens, click and open httpd.conf
2) Within the httpd.conf file search for “listen”. You’ll find two rows with something like:
#Listen 12.34.56.78:80
Listen 80
Change the port no to a port no. of your choice (e.g. port 1234) like below
#Listen 12.34.56.78:1234
Listen 1234
3) Next, in the same httpd.conf file look for “ServerName localhost:” Set it to the new port no.
ServerName localhost:1234
4) Save and close the httpd.conf file.
5) Now click the Apache config button again and open the “httpd-ssl.conf” file.
6) In the httpd-ssl.conf file, look for “Listen” again. You may find:
Listen 443
Change it to listen on a new port no of your choice. Say like:
Listen 1443
7) In the same httpd-ssl.conf file find another line that says <VirtualHost _default_:443>. Change this to your new port no. (like 1443)
8) Also in the same httpd-ssl.conf you can find another line defining the port no. For that look for “ServerName”. you might find something like:
ServerName www.example.com:443 or ServerName localhost:433
Change this ServerName to your new port no.
8) Save and close the httpd-ssl.conf file.
9) Finally, there’s just one more place you should change the port no. For that, click and open the “Config” button of your XAMPP Control Panel. Then click the, “Service and Port Settings” button. Within it, click the “Apache” tab and enter and save the new port nos in the “main port” and “SSL port” boxes. Click save and close the config boxes.
That should do the trick. Now “Start” Apache and if everything goes well, your Apache server should start up.
You will also see the Apache Port/s no in the XAMPP control panel has change to the new port IDs you set.
If the XAMPP server is running for the moment, stop XAMPP server.
Follow these steps to change the port number.
Open the file in following location.
[XAMPP Installation Folder]/apache/conf/httpd.conf
Open the httpd.conf file and search for the String:
Listen 80
This is the port number used by XAMMP.
Then search for the string ServerName and update the Port Number which you entered earlier for Listen
Now save and re-start XAMPP server.
Have you tried to access your page by typing "http://localhost:8012" (after restarting the apache)?
I had problem too.
I switced Port but couldn't start on 8012.
Skype was involved becouse it had the same port - 80. And it couldn't let apache change it's port.
So just restart computer and Before turning on any other programs Open xampp first change port let's say from 80 to 8000 or 8012 on these lines in httpd.conf
Listen 80
ServerName localhost:80
Restart xampp, Start apache, check localhost.
if don't work above port id then change it.like 8082,8080
Restart xammp,Start apache server,Check it.It's now working.
If its Ubuntu SYSTEM:
Go to
cd /opt/lampp/etc/
vim httpd.conf
Here you can change the Listen Port Number
If you want to change the SSL Port:
`vim /opt/lampp/etc/extra/httpd-ssl.conf` -> Change the SSL Listen port
and vim /opt/lampp/properties.ini -> Do the changes here as well
I am new to WAMP server and installed it on my system but after installing it when I check it by going to localhost url like this http://localhost/ in the browser it is not working. I am getting a 404 error and blank page.
This is because my 80 port which default in Wamp server is being used by IIS server. So please let me know how to change port number in Wamp server and solved this problem.
Click on the WAMP server icon and from the menu under Config Files select
httpd.conf. A long text file will open up in notepad. In this file scroll
down to the line that reads Port 80 and change this to read Port 8080,
Save the file and close notepad. Once again click on the wamp server icon and
select restart all services. One more change needs to be made before we are
done. In Windows Explorer find the location where WAMP server was installed
which is by Default C:\Wamp.
Update : On a newer version of WAMP, click the WAMP server icon > Apache > httpd.conf, then change the line Listen 80 to Listen 8080 or any port you want.
Update: On 3.1.6 version of WAMP , right click on the wamp server icon in the taskbar ,select "tools"-> "Port used by Apache:80" -> "use a port other than 80", an input box will pop up , input a new port in it,click confirm button , then restart wamp .
Just go to httpd.conf file, for ex. under WAMP environment its situated at:
C:\wamp\bin\apache\apache2.2.22\conf\httpd.conf
go to line no. 46 and edit Listen 80 to your requirement for ex.
Listen 8383
newer versions of WAMP uses these 2 lines:
Listen 0.0.0.0:8383
Listen [::0]:8383
Next go to line no. 171 and edit ServerName localhost:80 to your requirement for ex.
ServerName localhost:8383
Restart Apache and its done !!
Now, you can access with your URL:
http://localhost:8383 or http://192.168.1.1:8383
Hope it helps to people looking for solution here.
From the wampserver 3.x onwards, changing the listening port number of Apache does not require any particular Apache skills (http.conf, virtualhost,...), you just have to click button - assuming you're running Windows OS! :
In the tray, right click green/running WAMP icon
Select menu Tools
In the section Port used by Apache: xx, click Use a port other than 80 (i.e. default port configuration)
Enter the desired port number in the popup window - usually 8080 as alternative Web port
NB: For alternative port: check official IANA Service Name and Transport Protocol Port Number Registry
Change port number for Xampp
Go to the file
C:\xampp\apache\conf\httpd.conf
#Listen 12.34.56.78:80
Listen 80
Change 80 to 82
as
#Listen 12.34.56.78:82
Listen 82
now your url will be
http://localhost:82
In lieu of changing the port, I reclaimed port 80 as being used by IIS.
So I went to services, and stopped the following:
World Wide Web Publishing Services.
Web Management Service
Web Deployment Agent Service.
set them to manual so that it will not start on dev environment restart.
In addition of the modification of the file C:\wamp64\bin\apache\apache2.4.27\conf\httpd.conf.
To get the url shortcuts working, edit the file C:\wamp64\wampmanager.conf and change the port:
[apache]
apachePortUsed = "8080"
Then exit and relaunch wamp.
You could try changing Apache server to listen to some other port other than port 80.
Click on yellow WAMP icon in your taskbar
Choose Apache -> httpd.conf
Inside find these two lines of code:
Listen 80
ServerName localhost:80
and change them to something like this (they are not one next to the other):
Listen 8080
ServerName localhost:8080
Click on the WAMP server icon and from the menu under Config Files select
httpd.conf. A long text file will open up in notepad. In this file scroll
down to the line that reads Port 80 and change this to read Port 8080,
Save the file and close notepad. Once again click on the wamp server icon and
select restart all services. One more change needs to be made before we are
done. In Windows Explorer find the location where WAMP server was installed
which is by Default C:\Wamp.
I just installed the latest XAMPP and I changed httpd.conf so it listens on port 81 (because Skype listens on 80):
Listen 81
However when I use the XAMPP CP to launch Apache, it says:
Apache started [Port 80]
and then fails. If I stop Skype it says the same thing but doesn't fail and Apache listens on port 81, so my Apache config must be correct.
Why is XAMPP still checking port 80 and how do I stop it? I am running Windows 64-bit. XAMPP is installed in C:\xampp
I got the solution from XAMPP support so I'm answering my own question:
The solution was to change the port number in the sample XAMPP.INI file provided, then copy it to the xampp root dir.
There is another line further down in the .conf file that also needs changing.
ServerName localhost:80
Now start Apache and MySQL, browse to http://localhost:81, and the contents of your htdocs folder should appear.
Regarding the message displayed in the xampp window, I would ignore it. Mine displays '[Port 80]' regardless of which port I have set it to use.
This problem has completely shot my entire day. I reformatted my old windows XP comp and tried installing XAMPP only to find that when i try to start Apache xampp claims port 80 is busy....WHAT DOES THAT EVEN MEAN?
So I tried just uninstalling and moving to EasyPHP instead and when I installed that I get the error "error in Apache configuration file: the system cannot execute the specified program"
No, I do not have Skype or any other programs really for that matter at this point, like I said I JUST REFORMATTED so idk whats going on.
I would love to get this fixed, but if you leave me a answer please be specific on directions bc I'm only programming, never been to big on IT and playing with command lines and what not for me isn't to much fun.
Things to be done to free port 80:
check if skype is running, exit from skype
check services.msc if web deployment agent service is running
check if IIS is running, stop it.
Once you start apache, you can sign into skype.
Only one process can use port 80 at a time. Port 80 is the default port for web servers, so when you navigate to websites over HTTP, you are actually navigating to that server's port 80 by default (when you use HTTPS, the port is 443).
You can try to hunt down all the programs that are running on port 80, but there's an easier way that will work for development. When running XAMPP, click "Config" under "Apache". Replace Listen 80 with Listen 8080 and ServerName localhost:80 to ServerName localhost:8080.
Then, when you want to look at your masterpiece, navigate to http://localhost:8080 in your browser.
SQL Server Reporting Services (SSRS) SSRS can remain active even if you uninstall SQL Server.
To stop the service:
Open SQL Server Configuration Manager.
Select “SQL Server Services” in the left-hand pane.
Double-click “SQL Server Reporting Services”.
Hit Stop.
Switch to the Service tab and set the Start Mode to “Manual”.
Skype
Irritatingly, Skype can switch to port 80. To disable it, select Tools > Options > Advanced > Connection then uncheck “Use port 80 and 443 as alternatives for incoming connections”.
IIS (Microsoft Internet Information Server)
For Windows 7 (or vista) its the most likely culprit. You can stop the service from the command line.
Open command line cmd.exe and type:
net stop was /y
For older versions of Windows type:
net stop iisadmin /y
Other
If this does not solve the problem further detective work is necessary if IIS, SSRS and Skype are not to blame. Enter the following on the command line:
netstat -ao
The active TCP addresses and ports will be listed. Locate the line with local address “0.0.0.0:80″ and note the PID value. Start Task Manager. Navigate to the Processes tab and, if necessary, click View > Select Columns to ensure “PID (Process Identifier)” is checked. You can now locate the PID you noted above. The description and properties should help you determine which application is using the port.
Run this in command prompt:
netstat -ano | find ":80"
It will show you what process (PID) is listening on port 80.
From there you can open task manager, make sure you have PID selected in columns view option, and find the matching PID to find what process it is.
If its svchost.exe you'll have to dig more (see tasklist /svc).
I had this happen to me recently and it wasn't any of the popular answers like Skype either, could be Adobe, Java, anything really.
Port 80 might be busy with other application like IIS. If you don't want to stop it, you can change the apache port. Here is the way..
go to the C:\xampp\apache\conf (directory where you installed xampp). Now, locate the httpd.conf.
Open it with any text editor (like notepad) and go the line that says Listen 80
Change this with any other port (like Listen 1234)
Save the file. Restart the server and go ahead.
xampp port 80 is busy when some other application is using the same port at that time. This can be solved by using one of the following methods:
Detect the application which is using the port 80 and close it.
This one is more efficient. xampp installs apache server with default port 80. So, you can change this port manually to any number.
Just find the httpd.conf file in xampp installation and replace the following line of code.
#Listen 12.34.56.78:1234
Listen 80
to any port number of your choice. Here, i have taken 8000.
#Listen 12.34.56.78:1234
Listen 8000
Find the following code in the same file httpd.conf
ServerName localhost
Replace with the following, take the same number you have used in upper code.
ServerName localhost:8000
For detailed answer, check http://webolute.com/blog/programming/this-may-be-due-to-a-blocked-port-missing-dependencies
Just do one thing
open skype > tools > advance or advance settings Change port 80 to something else 7395
Restart your system then start Apache
I've found that the biggest culprit for taking up port 80 on newer Windows installs is the BranchCache Service (#3) in this list...
SQL Server Reporting Services
Web Deployment Agent Service
BranchCache
World Wide Web Publishing Service
These 4 service probably cover 90% of the native Windows Services that take up port 80.
The other 10% is the hidden HTTP.sys service/driver which takes port 80 when another service requests it. Run this to disable it, and reboot.
sc config http start= disabled
Aside from Skype, TeamViewer is also very commonly installed software, and will take port 80 if not configured otherwise.
List taken from: Opening Up Port 80 For Apache to Use On Windows
If you are running VMWare Workstation , you need to stop the VmWare Workstation server - port 443 as well
So I have faced the same problem when trying to start apache service and I would like to share my solutions with you.
Here is some notes about services or programs that may use port 80:
Skype: skype uses port 80/443 by default. You can change this from tools->options->
advanced->connections and uncheck the checkbox "use port 80 and 443 for addtional incoming connections".
IIS: IIS uses port 80 be default so you need to shut down it. You can use the following two commands
net stop w3svc
net stop iisadmin
SQL Server Reporting Service: You need to stop this service because it may take port 80 if IIS is not running. Go to local services and stop it.
These options work great with me and I can start apache service without errors.
The other option is to change apache listen port from httpd.conf and set another port number.
Hope this solution helps anyone who face the same problem again.
This happens because some other programs running in your system is using the default port 80 used for http service by apache server in xampp/easy php.
Some programs like skype usually use port 80.
so find such program and remove it ...
For finding programs listening port 80 refer Port 80 listening programs
Try finding the Service running on the PID that is blocking the service from Task manager->Services
In case this isn't of help go to Task Manager->Services
Go to the Services button on bottom right of window and stop the Web Deployment Agent Service. Retry starting Apache . That might solve the problem.
This problem is because port 80 is used by some other application. Try to reconfigure port.
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/