How To Troubleshoot XAMPP Apache Not Running on Windows 7

38

XAMPP is one of the popular Web development tool for Windows. It is an aggrupation of Apache server, Mysql database and some FTP services, if you choose to install. It comes with a simple control panel, where you can start or stop a service locally with just a button of click.

Lately, I’ve experience issues with XAMPP, it won’t able to start Apache, doesn’t matter how much time I clicked that start button it won’t start my local server and there is no error showing from the XAMPP control panel. In that case there are few methods you can try to figure out what’s wrong with your XAMPP won’t able to start Apache server.

Method one: If no error is showing via XAMPP, start Apache from CMD

This method almost always give you more information. To do that simply launch your cmd from start menu.

Navigate to where XAMPP install dir, or drag the batch file “apache_start” to the command prompt and run the batch file. If this is the first time you have install XAMPP, meaning you have yet to have the chance to configure which language to display, the error message you get might not be in English. In this some part of the error message is showing in English. So we are lucky enough to identity the problem.

Only one usage of each socket address (protocol/network address/port) is normally permitted. make_sock: could not bind to address [::]:433

2012 04 02 2001 thumb - How To Troubleshoot XAMPP Apache Not Running on Windows 7

It appears that Apache won’t able to start is because port 443 is taken by some other processes. First of all, why Apache need port 443 ? Well apparently, port 443 is the default port for HTTPS, and 80 for HTTP. In order for Apache to start, the default configuration of Apache requires to have both port open.

So that lead to us, how do I know which application is using port 443 ?

If you run the following commend

netstat -o -n -a | findstr 0.0:443

2012 04 02 2001 001 thumb - How To Troubleshoot XAMPP Apache Not Running on Windows 7

You can see that there is this application with PID 2064 is currently using this port, more specifically it’s listening this port.

So now the question is, how do I know which process is running with the PID 2064 ?

It’s easy, go to Task Manager >; (Process Tab) View >; Select Columns …  Pick PID (should be the first if not checked)

2012 04 02 2002 thumb - How To Troubleshoot XAMPP Apache Not Running on Windows 7

Now we go back to Task Manager, woha ! We’ve found the process that with the PID 2064. It appears it’s something running from VMware. wmware-hostd.exe is running, and this is the process that’s causing trouble occupying port 443 lead to Apache won’t start.

Two Solutions on Apache won’t start due to port 443 taken by other applications

There are two ways you can go around this, first the most obvious way is to stop the process that’s currently running which is using port 443. You can kill it by press “End Process”. But things didn’t just solve itself that easily in my case. Sometimes after killing the process, it will automatically restart again. I tried to search on VMware forum to disable or change the port but no success.

So this lead to my second approach, which is to change the apache HTTPS 443 port to something else, that are currently not listened by any other processes.

If you go to C:xampp\apache\conf\extra\httpd-ssl.conf (or wherever your XAMPP or apache installed)

2012 04 03 0022 thumb - How To Troubleshoot XAMPP Apache Not Running on Windows 7

Find the line where it says Listen 443, change it to Listen 4330 OR some other port that you know for sure no other process will use. Save it and go to XAMPP control panel to start apache.

And guess what ! Now you have apache running again.

2012 04 02 2359 thumb - How To Troubleshoot XAMPP Apache Not Running on Windows 7

This is just one of the issues I’ve encountered. I’m sure there are other people will have the same issue and have no idea where to start. This is happening with my Windows 7 machine running VMware Workstation 8.0. I don’t recall back when I have WorkStation 7.x I encountered this issue. So it must been with the new version of VMware Workstation that caused this. Of course, another way to fix this issue is to uninstall VMware Workstation 8, but I suppose that’s not a very good solution

38 COMMENTS

  1. Worked – thanks. Might be worth noting I had to press ‘Show processes from all users’ to get all the processes including the offending vmware server to show.

  2. I’m afraid this doesn’t work for me. This is my first time trying to get xampp working, and I get the error with vmware. Changed the config file (3 places), but the error persists. Is it generated somewhere else?

  3. Another reason which I encountered is:

    Installed Magento on XAMPP using Bitnami

    Installation got stuck and I cancelled it.

    It already made an entry in httpd.conf

    # AJP13 Proxy

    Include “conf/extra/httpd-ajp.conf”

    Include “D:/xampp/apps/wordpress/conf/httpd-prefix.conf”
    #Include “D:/xampp/apps/magento/conf/httpd-prefix.conf”

    I just commented the last line as Apache wasn’t starting and now it runs fine.

    Thanks for hinting to start Apache from cmd window. It showed the error.

LEAVE A REPLY

Please enter your comment!
Please enter your name here