Apache is not starting After upgrading PHP 7.0.9 to PHP 7.0.30 in XAMPP - xampp

Right now, my xampp has php 7.0.9 version. Now, I want to upgrade it to php 7.0.30. So, as per guidelines and tutorials shared on internet, I have download thread safe 64 bit php 7.0.30 from below URL:
Downloaded PHP 7.0.30 from Here
And put this folder into xampp folder. After this, I have updated xampp configuration file.
After doing all of the above steps, when I am trying to restart/start apache it is not starting and showing me below error:
Error: Apache shutdown unexpectedly.
5:47:27 PM [Apache] This may be due to a blocked port, missing dependencies,
5:47:27 PM [Apache] improper privileges, a crash, or a shutdown by another method.
5:47:27 PM [Apache] Press the Logs button to view error logs and check
5:47:27 PM [Apache] the Windows Event Viewer for more clues
5:47:27 PM [Apache] If you need more help, copy and post this
5:47:27 PM [Apache] entire log window on the forums
I have also tried to start Apache even after shutting down my SKYPE but still not starting.
Can anyone please help me on this?

Instead of downloading from php.net I've had better luck downloading the portable version of XAMPP directly from sourceforge. You can then take the php directory from the downloaded zip and (after renaming your current php directory) copy it into the xampp directory.
I found that I also had to copy over the ng2http2.dll and libssh2.dll from the (new) php directory to the xampp/apache/bin directory (again after renaming old files).
After a quick check of the new php.ini file and starting the XAMPP server, my local sites loaded the new version.
The above worked for me upgrading from PHP 7.0.x to 7.1.x on Windows 10.

Related

Why isn't wamp starting? (there's no apache logs)

I installed wamp on windows 8.1 and it's not starting. Apache, mysql and php, none of it has started. I checked my antivirus and antikeylogger and it's not being blocked. When I check the apache error log and apache access log, it says that the log files do not exist. Without a log file, how do I troubleshoot the error?

XAMPP windows 7 - Apache shutdown unexpectedly... suddenly, and I do not wyy

I have on my laptop installed XAMPP. It was running for years… (v3.1.x, not the latest version) No problem at all.
Suddenly saterday evening I try to start the appache server by xampp control panel and I get the next error:
19:33:25 [Apache] Error: Apache shutdown unexpectedly.
19:33:25 [Apache] This may be due to a blocked port, missing dependencies,
19:33:25 [Apache] improper privileges, a crash, or a shutdown by another method
19:33:25 [Apache] Press the Logs button to view error logs and check
19:33:25 [Apache] the Windows Event Viewer for more clues
19:33:25 [Apache] If you need more help, copy and post this
19:33:25 [Apache] entire log window on the forums
I have been googling and searching.
I have Skype already disabled port 80/443 at the time I have
installed Skype
I have changed httpd.conf; Listen 8080 in stead of 80; Listen 4433 in stead of 443
I have also been searching who is using port 80 by Netstat xampp panel. I do not see any PID process with porth 80
I have activate “show debub information”, but I don’t see information of an error.
There is nothing written in the error.log. When it happen it was 5-12-2015 and I the last lines in the error logs are from
3-12-2015.
I have downloaded the latest XAMPP version (zip), unzipped first put it in a different directory. Same error
I have tried to look in the windows event viewer but I couldn't find anything or I'm not looking in the good log item in windows
I have done all these command with the cmd:
net stop http
netstat –abno
netstat -abno | find ":80"
netstat -abno | find ":443"
netstat -a –b
netstat –ano
Not a result that port 80 is used. So it seems to me that it is NOT a port issue.
It is on window 7 system, bitdefender total security 2015, wich is already installed in july of this year.
I download always the XAMPP zip version and start xampp always by the control panel not as a service.
Has anybody an idea what has happen or what could be happen?
I have also read these links
XAMPP, Apache - Error: Apache shutdown unexpectedly
https://stackoverflow.com/questions/788348/how-do-i-free-my-port-80-on-localhost-windows
https://stackoverflow.com/questions/14245474/apache-wont-run-in-xampp

XAMPP - Apache could not start - Attempting to start Apache service

While trying to start Apache using XAMPP, I was receiving - "Attempting to start Apache service..." message in XAMPP UI. No further details were available.
Where can I see the logs (I was running XAMPP as Admin) ?
IF PORT 80 IS NOT THE ISSUE!
Check to see if the port 80 is in use first as this can be an issue.
You can do this by typing "netstat -an" into cmd. The look for 0.0.0.0:80 under Local Address, if you find this is in use then follow the solution from #Karthik. However, I had a similar issue but my port 80 was not in use.
My XAMPP had wrong paths locations, steps to fix this:
1.Find out the Apache version you are using, you can find this by looking in Services (Control panel, Admin Tools, Services) and finding Apache in my case it was listed as Apache2.4
2.Close XAMPP.
3.Run cmd as admin.
4.execute 'sc delete "Apache2.4"' (put your version in place of mine and without the surrounding ' ', but with the " " around Apache).
5.execute 'sc delete "mySQL"', again remove the '' when you type it.
6.reopen XAMPP and try starting Apache
If you are having trouble with FileZill, Mercury, or Tomcat you could try it here too, but I have not tested that myself.
Hope this helps!
I realized it was a port issue since I was running IIS and other web servers in my machine. But I was more interested to see a detailed error message with the port number in the UI.
Seems like it was not logged in the UI or log file (at least in my case), but in the Event viewer (Control panel -> View Event Logs). Under the Even viewer -> Windows Logs -> Application
I could see a permission error something like the below one:
An attempt was made to access a socket in a way forbidden by its access permissions. : AH00072: make_sock: could not bind to address 0.0.0.0:443
To fix this permission issue for SSL port, Please change the below line in httpd-ssl.conf (C:\xampp\apache\conf\extra)
# When we also provide SSL we have to listen to the
standard HTTP port (see above) and to the HTTPS port
Listen xxx
Replace XXX with any valid port number that is open in your machine
If you are having issues with Port 80, then change the httpd.conf file (C:\xampp\apache\conf)
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 127.0.0.1:8000
I have also summarized other solutions that I came across:
Most often Skype blocks the Apache port. So terminate it and try again.
Find the process id (PID) that is using the Blocked port ( netstat -ano) and kill the corresponding process in Windows Task Manager.
For those who have accidentally (or not) changed one of the .conf files and apache does not run even after trying all the above solutions.
One easy way to track where the issue is located, is to run Apache via command prompt:
(On windows) : open command prompt as admin then navigate inside the bin folder of Apache , next run
httpd in order to run apache
C:\xampp\apache\bin\httpd
For my case it was :
someone had added a virtual host in the specific file that caused the problem . I commented the lines and Apache ran fine.
start xampp (as administrator),
(1) right click C:\xampp\xampp-control.exe, and run as administrator.
(2) unistall service module and then install service module.
(3) now try start the apache and mysql.
Check your DocumentRoot path (in httpd.conf); a typo there can cause this problem.
Had the same issue while updating to PHP7.2
Problem:
First I closed skype and then checked whether port 80 is not an issue. How you can check that? See #AlexT comment above.
In my case, port 80 wasn't an issue. So now I had to figure out what was wrong. So I checked Error Logs Control Panel > Even viewer > Windows Logs > Application and found following error against Apache2.4
httpd.exe: Syntax error on line 520 of C:/xampp/apache/conf/httpd.conf: Syntax error on line 18 of C:/xampp/apache/conf/extra/httpd-xampp.conf: Cannot load C:/xampp/php/php7ts.dll into server: The Apache service named is not a valid Win32 application.
Which means I had installed wrong PHP version. Actually I downloaded win64 version while the required version was Win32 for me.
So I downloaded correct version from: Download PHP 7.2.0 extracted it in C:/xampp/php folder, restarted the apache and it worked :)
I had the same issue, executing "setup_xampp.bat" in xampp folder solved my issue.
I had the same problem but it was because I had a previous version of xampp already installed and I tried to install a newer version. I had installed the newer version in another file directory (I had named the file directory xampp2). I solved the problem by uninstalling the newer version, renaming the old one (I renamed it xamppold) and I installed xampp again.
I guess if you haven't installed xampp in another file directory , it should be enough to reinstall xampp. If you are worried about your files , you always can make a backup before reinstalling xampp.
I solved the problem after watching the xampp activity log (the list of the bottom) and realizing xampp was trying to open the custom file path but I had another route path. If the first option didn't work, at least you can scroll up in the activity log and see what's error you get while starting as admin and trying to re install the Apache module or trying to start the module.
You may wander why I didn't just simply uninstall the whole thing from the beginning , and the answer would be because I had to tweak a couple of things in xampp for some different projects (from changing the ports , to add .dll to run mongo.db in Apache), and I was just too lazy to re-do everything again :b
I hope my answer can be helpful for anyone since this is my first time writing in stackoverflow :)
Cheers
In my case, with the same problem and Xampp window, I had copied \apache\conf\extra\httpd-vhosts.conf entries from an old Xampp version to a newly installed one so I could continue to open local projects in browsers. One of the vhosts paths was wrong. After deleting that entry Apache started without problem.
The reference by #Karthik to "in the Event viewer (Control panel -> View Event Logs" saved me time. It's all too easy to presume Xampp logs will point to the problem. It doesn't.
Also check if your xampp is installed in the main directory like C or D or E and not in or within a folder of that directory? i.e. ( "D:/Xampp" or is it "D:/something/Xampp") if its not in the main path of the directory, it will show this error.
copy your xampp directory from "D:\Something\Xampp" to "D:"
So it becomes like this "D:\Xampp"
and the issue will be resolved.
Starting Xampp as a console application (simply by doubleclicking xampp_start.exe in the Xampp root folder) was the only thing that worked for me on Windows 10 (no Skype, no Word Wide Web Publishing Service). WampServer and UwAmp also didn't work.
I had a hard-coded IP in httpd.conf and my local IP had changed which was causing my issue, changed IP over and all worked again
My scenario was different after I tested all the possible options. If you have changed the ports and still get the same problem, well here's something you can try out. This was done in Windows 7.
Step 1: Confirm the cause of the error by going to Control Panel -> System and Security -> Administrative Tools -> Event Viewer -> Windows Logs -> Application -> Error. Mine said "The Apache service named reported the following error:
httpd.exe: Syntax error on line 424 of C:/xampp/apache/conf/httpd.conf: Cannot load c:\xampp\php\php5apache.dll into server: The specified module could not be found." So I needed to change \php5apache.dll to the version of my php and apache version installed which was php7apache2_4.dll
Step 2: To get the correct name for your .dll php and apache file, got to C:\xampp\php. You will see something like php7apache2_4.dll with other files in the folder.
Step 3: Go to C:/xampp/apache/conf/httpd.conf and edit the configuration file and change "c:\xampp\php\php5apache.dll" to "c:\xampp\php\php7apache2_4.dll" in my case. Make sure you open the file as administrator save changes made.
Step 4: Run the xampp server and everything should work fine. Do not forget to shut down the xampp server before doing the changes to the apache configuration file.
Hope this helps. Cheers! :)
Try to install x86 version of XAMPP. The default XAMPP version on their website is x64 (maybe because I'm using x64 Windows 7).
download link here
I had this issue when I installed under Program Files, which they do not recommend due to write issues. This might only be a problem if you are not logged in as an admin and use a password to install. I just uninstalled and installed in a directory that did not need admin privileges.
Make sure Apache didn't get Disabled in Services (Control panel, Admin Tools, Services). If it's Disabled then Set it to Manual and it should run. That was my case, I found Apache Disabled.
Solution for my particular scenario (It had been working a couple days before getting borked):
Port 80 was not the problem, but something I had done while messing around with Services and Startup.
Type msconfig on Windows' Start menu
Click System Configuration
Screenshot for System Configuration
In the Services tab, search for Apache24 (Click "Hide all Microsoft services" in the checkbox at the bottom of the window to make it easier to find)
If its checkbox isn't checked, check it
If it was already checked, then this guide isn't going to help. However if it is:
Click OK, your PC will have to restart
Try once again! In my case Apache was already running once I opened Xampp
I had the same issue.Just click on services button.Then find apache and right cick > properties > set startup type as Automatic/ Manual. Now close apache and try again.It will work!
For me it wasn't a port or service issue; I had to re-run the XAMPP setup script. Although this didn't directly fix the issue for me, the script was much more verbose than the XAMPP log, pointing me in the right direction to actually solve the problem.
From the XAMPP GUI, click on Shell, type set, press Tab to autocomplete to the setup_xampp.bat file, and then press Enter to run it.
In my case I got the following output:
[ERROR]: Test php.exe failed !!!
[ERROR]: Perhaps the Microsoft C++ 2008 runtime package is not installed.
[ERROR]: Please try to install the MS VC++ 2008 Redistributable Package from the Mircrosoft page first
[ERROR]: http://www.microsoft.com/en-us/download/details.aspx?id=5582
This particular error is misleading. Although it specifies the Visual C++ 2008 Redistributable Package, PHP 7.4.x requires the Visual C++ 2019 Redistributable Package.
After installing that and following the prompt to restart, sure enough I'm now able to start Apache as normal.
make sure no space in front of the port number if you ever edited it.
From Xampp control panel, click on config (next to Apache), then choose Apache(httpd.config), search for listen 80 and change the port to another port.
If nothing works with you, I would suggest you download MAMP and use it instead.
It does the same thing, if not better.
Comment this lines from httpd.conf:
# Virtual hosts
#Include etc/extra/httpd-vhosts.conf
In the case you're using them it may solve.
when i run xampp control panel normal:
I had been run
I can’t start apache
So, I will run it with administrator:
I can run apache

Apache won't start in wamp

I have been googling for the past few hours but I simply can't get my apache on wamp to start. My skype isn't running, and the test port 80 shows it isn't being used by anything. Before this happened, I was trying to add a new vhost, but now I have reverted back all of the files where I made changes. Anyway to debug why apache won't start?
Clicking on start/resume service for apache doesn't show any errors either.
Also just in case, I am running Win7 64bit
If you have an issue in the httpd.conf or any files included by it there are a couple of ways to find out what the problem is
First look at your Windows Event Viewer. Click on the Windows link in the menu on the left, and then submenu Applications.
Look for messages from Apache with the red error icon.
Secondly, open a command window, then CD into \wamp\bin\apache\apache2.x.y\bin, replace x,y with your actual version.
Now you can run this command to get Apache(httpd) to validate the httpd.conf file.
httpd.exe -t
This should give errors with line numbers related to the http.conf file.
It stops on the first error, so you will have to keep running it and fixing the error and then run it again until it gives the all OK message.
Use apaches startup debug tool from command: httpd.exe -e warn
press Win+R
type cmd and press enter
goto directory which contains your apache httpd.exe file. for example if your wamp is installed in e:\wamp type cd /d e:\wamp\bin\apache\ApacheX.X.X\bin in cmd and press enter.
type httpd.exe -e warn (or httpd.exe -e debug for more details) to see error message about problem which is prohibiting apache to start.
That is what I did and it helped me to find out what my Apache-PHP needed:
C:\Users\Admin>cd C:\wamp\bin\apache\apache2.4.9\bin
C:\wamp\bin\apache\apache2.4.9\bin>httpd -t
Syntax OK
C:\wamp\bin\apache\apache2.4.9\bin>httpd -k start
[Thu Apr 23 14:14:52.150189 2015] [mpm_winnt:error] [pid 3184:tid 112]
(OS 2)The system cannot find the file specified. : AH00436:
No installed service named "Apache2.4".
C:\wamp\bin\apache\apache2.4.9\bin>
The most simple solution:
Uninstall and reinstall WAMP (do not even try to set it up on top of existing installation - it would not help)
P.S.
If you wonder how did I get to this situation, here is the answer: I was trying to install WAMP and it throws me an error in the middle of installation saying:
httpd.exe - System Error
The program can't start because MSVCR110.dll is missing from your computer.
Try reinstalling the program to fix this problem.
OK
I got and installed Microsoft Visual C++ 2012 Redistributable from here http://www.microsoft.com/en-us/download/details.aspx?id=30679#
And it gave me the "dll" and the MYSQL started working, but not Apache.
To make Apache to work I uninstalled and reinstalled WAMP.
This solved the issue for me:
Right click on the WAMP system try icon -> Tools -> Reinstall all services
Go to C directory and then go to below mentiond path of you wamp server.
C:\wamp64\bin\apache\apache2.4.46\bin>
Then in Address bar enter "CMD" and press enter.that wil open the command prompt.
Now past below comman
httpd.exe -e warn
to see error message about problem which is prohibiting apache to start.
If you error is releated to port then
Right click on wamp server than on apache and then on httpd.confg,
Now search 80 and replace with 81 in that file and close and restart wamp
Invalid Command '80HostnameLookups' , perhaps misspelled or defined by a module not included in the server configuration
I got this error when I debug the issue (wamp server was not going online) by the procedure defined by #RiggsFolly. Just comment the line 80HostnameLookups Off by changing it to #80HostnameLookups Off.
This solution worked for me and apache starts running.Note:80HostnameLookups Off can be found on line 222 of httpd.conf file located in C:\wamp\bin\apache\apache2.4.9\conf
phpmyadmin.conf opened with apacheconf.exe and contents chained so you must do the following:
copy contents of phpsysinfo.conf [C:\wamp\alias]
paste into phpmyadmin.conf [C:\wamp\alias]
change Alias /phpsysinfo "c:/wamp/apps/phpsysinfo3.1.12/" to Alias /phpmyadmin "c:/wamp/apps/phpmyadmin4.1.14/"
change <Directory c:/wamp/apps/phpsysinfo3.1.12/ /> to <Directory c:/wamp/apps/phpmyadmin4.1.14/ />
its worked for me.
My solution was that 2 .dll files(msvcp110.dll, msvcr110.dll) were missing from the directory :
C:\wamp\bin\apache\apache2.4.9\bin
So I copied these 2 files to all these locations just in case and restarted wamp it worked
C:\wamp
C:\wamp\bin\apache\apache2.4.9\bin
C:\wamp\bin\apache\apache2.4.9
C:\wamp\bin\mysql\mysql5.6.17
C:\wamp\bin\php\php5.5.12
I hope this helps someone out.
Sometimes it is Skype or another application "Holding" on to port 80. Jusct close Skype
My solution on Windows 10 was just to stop IIS (Internet Information Services).
If Apache is installed as a Windows service, any errors will show up in the Windows System event log. To view the System event log, navigate to Windows Administrative Tools->Event Viewer and open the System log in the Windows Logs folder. Or, you can see the same errors by running httpd.exe at the command line. In my case, httpd.exe is located here: C:\Bitnami\wampstack-5.6.26-2\apache2\bin.
If there is a problem with starting Apache, most likely the problem can be fixed by editing the httpd.conf file located in the \apache2\conf folder.
As already suggested, you can check the syntax of the httpd.conf file by running httpd.exe -t at the command line.
I found that the I had to
Change SetEnv PATH "C:\Bitnami\wampstack-5.6.26-2\apache2\bin;${PATH}" in httpd.conf
to
SetEnv PATH "C:\Bitnami\wampstack-5.6.26-2\apache2\bin;%PATH%"
I had the same problem. My port 80 was not in use.
After thorough research, all I did was to download Update for Universal C Runtime.
Once installed and my PC restarted, all was OK.
I was having the same problem, the mysql service was starting but not the apache service, the main problem about that is one of your virtual hosts isn't config. correctly, all i did was deleted the virtual host that i created "D:\wamp\bin\apache\apache2.4.23\conf\extra\httpd-vhosts, restarted all services apache service started working correctly and so i just went to localhost and added a virtual host automatically and so it worked!!
I was having same problem.
I followed this steps, problem solved.
run command line (CMD) with Administrator Permission.
cd c:/wamp64/bin/apache/apache2.4.27/bin
httpd.exe -k uninstall
httpd.exe -k install
at last restart all services from wamp system tray icon
It turns out I didn't have Microsoft visual c++ installed, installing it solved the problem for me.
If you have Microsoft Visual Studio running at time of running, try to disconnect it and try again

OpenEMM Installation

Guys, I have installed OpenEMM 2013 on Windows 2012 Server. Everything works fine as per installation guide but when I am trying to start the OpenEMM using start.bat, I am facing some problem.
It says's -
Starting up .. home is C:\OpenEMM .. found codebase .. warning: no MySQL found using reg.key SOFTWARE\MySQL AB, continue anyway found database.
Running, press return for termination:
Also I have found the log file in the /var/log/openemm_stderr.log
SEVERE: Could not contact localhost:8005. Tomcat may not be running.
I have opened the port - 8005,8009,8443,8080 in my Firewall. But still I can not start openemm service.

Resources