0

I quit the skype i though same port but still not working.. I tried with restart my pc and restarted Xamppp. But Not Working.

   8:47:28 PM  [Apache]  Attempting to start Apache app...
    8:47:28 PM  [Apache]  Status change detected: running
    8:47:28 PM  [Apache]  Status change detected: stopped
    8:47:28 PM  [Apache]  Error: Apache shutdown unexpectedly.
    8:47:28 PM  [Apache]  This may be due to a blocked port, missing dependencies, 
    8:47:28 PM  [Apache]  improper privileges, a crash, or a shutdown by another method.
    8:47:28 PM  [Apache]  Press the Logs button to view error logs and check
    8:47:28 PM  [Apache]  the Windows Event Viewer for more clues
    8:47:28 PM  [Apache]  If you need more help, copy and post this
    8:47:28 PM  [Apache]  entire log window on the forums
    8:47:30 PM  [Apache]  Problem detected!
    8:47:30 PM  [Apache]  Port 80 in use by "Unable to open process" with PID 4!
    8:47:30 PM  [Apache]  Apache WILL NOT start without the configured ports free!
    8:47:30 PM  [Apache]  You need to uninstall/disable/reconfienter code heregure the blocking application
    8:47:30 PM  [Apache]  or reconfigure Apache and the Control Panel to listen on a different port
    

I am using xampp i am getting error while starting xampp how to resolve this error.

Mr world wide
  • 4,696
  • 7
  • 43
  • 97
  • 1
    As per the log you can see this 'Port 80 in use by "Unable to open process" with PID 4!', see what is using this port or configure a different port. – Arathi Sreekumar Aug 12 '16 at 15:24
  • how to configure different port..? @Arathi – Mr world wide Aug 12 '16 at 15:27
  • Maybe this will help http://stackoverflow.com/questions/3940909/configure-apache-to-listen-on-port-other-than-80, I am not that familiar with apache. Just interpreted what you posted, it clearly says port in use. – Arathi Sreekumar Aug 12 '16 at 15:28

1 Answers1

1

SOLUTION:

On your XAMPP Control Panel, Stop Apache Module, click on Config button, then select Apache (httpd.conf). Find (Ctrl+F) 80 on the file. Replace all 80s with a random value you like (8080 looks good) and save the file. Now click on Config button, then select Apache (httpd-ssl.conf). Find (Ctrl+F) 443 on the file. Replace all 443s with a random value you like (4433 looks good) and save the file. Start the Apache Module again. Now APACHE must work fine :)

NOTE:

If you would like to know the exact reason for this error, open your Task Manager and go to Details tab. Find the process with the PID mentioned on the XAMPP error log. Here what exactly has happened is your port is busy with another process which is indicated by the PID (Process ID). So in the solution, what we did is, allocating another port for APACHE.

ADDITIONAL TIP:

When you type localhost on your browser's address bar, it uses the port 80 by default. But since you make changes to the default ports of Apache Module, make sure you adjust your localhost's address accordingly. For an example, if you change your port 80 to port 8080, you will have to use http://localhost:8080/ all the time on the browser, so that your browser will know Apache is now using port 8080, not the default port.

See it is not hard :) In your topic, you say "..database is not working", but the error log has no mention on MySQL. If your MySQL module also has the same error, you have to do a simple port configuration as above. If you get stuck, you can find the steps from my blog article: http://ashenlive.blogspot.com/2016/08/web-programming-with-php.html

Thilina Ashen Gamage
  • 1,367
  • 1
  • 12
  • 21
  • 1
    Thanks man, your tricked worked for me. For others banging their heads due to this error. Plz follow 2 steps: 1. change port 80 in httpd.conf to a value like 81 or 82 or 8080 etc. 2. change port 443 in httpd-ssl.conf to a value like 4433 etc. and then restart apache from control panel. – iltaf khalid Oct 26 '18 at 14:51