Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

PHP

Haven't been able to get XAMPP working

Yesterday, I spent 4 hours on this. Feelin' a little frustrated. Anyway....

I installed XAMPP but have never gotten passed starting apache. AfterI start the XAMPP control panel, and select the start button for apache I get the following error.

10:51:01 AM [Apache] Checking default ports... 10:51:01 AM [Apache] Attempting to start Apache app... 10:51:01 AM [Apache] Executing "d:\xampp\apache\bin\httpd.exe" 10:51:01 AM [Apache] Return code: 0 10:51:01 AM [Apache] Status change detected: running 10:51:02 AM [Apache] Status change detected: stopped 10:51:02 AM [Apache] Error: Apache shutdown unexpectedly. 10:51:02 AM [Apache] This may be due to a blocked port, missing dependencies, 10:51:02 AM [Apache] improper privileges, a crash, or a shutdown by another method. 10:51:02 AM [Apache] Press the Logs button to view error logs and check 10:51:02 AM [Apache] the Windows Event Viewer for more clues 10:51:02 AM [Apache] If you need more help, copy and post this 10:51:02 AM [Apache] entire log window on the forums

Any Suggestions?

11 Answers

I seem to remember something about it using Port 80 and a conflict with Skype. If you are using Skype Go to "Tools -> Options -> Advanced" and uncheck "use port 80 and 443".

When I set it up I followed this guide: http://docs.grabaperch.com/solutions/development-guides/xampp-install/

  • just ignore the bits at the end about installing Perch CMS

Sorry, I have never used skype. I just checked and it isn't installed on my computer. My computer is using Windows 7. Don't know what else you would need to know so tell me if there is more information that you need.

thanks for your help

Something else I noticed. On all of the screen shots I have seen for the XAMPP control panel, various services are selected. When the control panel comes up on my computer none of the services are selected. I tried to auto start apache and got the following log messages in the control panel

10:46:33 AM [Apache] Initializing module... 10:46:33 AM [Apache] Checking for module existence... 10:46:33 AM [Apache] Checking for required tools... 10:46:33 AM [Apache] Checking for service (name="Apache2.4"): Service not installed 10:46:33 AM [Apache] Service Path: Service Not Installed 10:46:33 AM [Apache] Checking default ports... 10:46:33 AM [mysql] Initializing module... 10:46:33 AM [mysql] Checking for module existence... 10:46:33 AM [mysql] Checking for required tools... 10:46:33 AM [mysql] Checking for service (name="mysql"): Service not installed 10:46:33 AM [mysql] Service Path: Service Not Installed 10:46:33 AM [mysql] Checking default ports... 10:46:33 AM [filezilla] Initializing module... 10:46:33 AM [filezilla] Checking for module existence... 10:46:33 AM [filezilla] Checking for required tools... 10:46:33 AM [filezilla] Checking for service (name="FileZillaServer"): Service not installed 10:46:33 AM [filezilla] Service Path: Service Not Installed 10:46:33 AM [filezilla] Checking default ports... 10:46:33 AM [mercury] Initializing module... 10:46:33 AM [mercury] Checking for module existence... 10:46:33 AM [mercury] Checking for required tools... 10:46:33 AM [mercury] Checking default ports... 10:46:33 AM [Tomcat] Initializing module... 10:46:33 AM [Tomcat] Checking for module existence... 10:46:33 AM [Tomcat] Checking for required tools... 10:46:33 AM [Tomcat] Checking for service (name="Tomcat7"): Service not installed 10:46:33 AM [Tomcat] Service Path: Service Not Installed 10:46:33 AM [Tomcat] Checking default ports...

thanks don

I believe which you can choose which modules to include during the initial xampp installation (lots of notes about things not being installed in your log).

I'm no expert with xampp - you may find better advice on their own forums for xampp in Windows here: http://www.apachefriends.org/f/viewforum.php?f=16

Thanks, I have been looking at their forum as well and haven't had much luck their either.

Open your command prompt and run this command and post the output to this thread

netstat -an | find /i "listening"

This command lists all of the ports your computer is *"listening" on, so we can see if there is one that may be conflicting with your XAMPP installation.

Here is the out put.

9:52:22 AM [main] Initializing Control Panel 9:52:22 AM [main] Windows Version: Windows 7 Home Premium SP1 64-bit 9:52:22 AM [main] XAMPP Version: 1.8.3 9:52:22 AM [main] Control Panel Version: 3.2.1 [ Compiled: May 7th 2013 ] 9:52:22 AM [main] Running with Administrator rights - good! 9:52:22 AM [main] XAMPP Installation Directory: "d:\xampp\" 9:52:22 AM [main] Checking for prerequisites 9:52:22 AM [main] All prerequisites found 9:52:22 AM [main] Initializing Modules 9:52:22 AM [main] Starting Check-Timer 9:52:22 AM [main] Control Panel Ready 9:52:31 AM [Apache] Attempting to start Apache app... 9:52:31 AM [Apache] Status change detected: running 9:52:32 AM [Apache] Status change detected: stopped 9:52:32 AM [Apache] Error: Apache shutdown unexpectedly. 9:52:32 AM [Apache] This may be due to a blocked port, missing dependencies, 9:52:32 AM [Apache] improper privileges, a crash, or a shutdown by another method. 9:52:32 AM [Apache] Press the Logs button to view error logs and check 9:52:32 AM [Apache] the Windows Event Viewer for more clues 9:52:32 AM [Apache] If you need more help, copy and post this 9:52:32 AM [Apache] entire log window on the forums

sorry posted the wrong information, This is the output from netstat -an | find /i "listening"

Microsoft Windows [Version 6.1.7601] Copyright (c) 2009 Microsoft Corporation. All rights reserved.

C:\Windows\system32>netstat -an | find /i "listening" TCP 0.0.0.0:135 0.0.0.0:0 LISTENING TCP 0.0.0.0:445 0.0.0.0:0 LISTENING TCP 0.0.0.0:49152 0.0.0.0:0 LISTENING TCP 0.0.0.0:49153 0.0.0.0:0 LISTENING TCP 0.0.0.0:49154 0.0.0.0:0 LISTENING TCP 0.0.0.0:49171 0.0.0.0:0 LISTENING TCP 0.0.0.0:49186 0.0.0.0:0 LISTENING TCP 127.0.0.1:5354 0.0.0.0:0 LISTENING TCP 127.0.0.1:27015 0.0.0.0:0 LISTENING TCP 127.0.0.1:49157 0.0.0.0:0 LISTENING TCP 127.0.0.1:49158 0.0.0.0:0 LISTENING TCP 192.168.1.27:139 0.0.0.0:0 LISTENING TCP [::]:135 [::]:0 LISTENING TCP [::]:445 [::]:0 LISTENING TCP [::]:49152 [::]:0 LISTENING TCP [::]:49153 [::]:0 LISTENING TCP [::]:49154 [::]:0 LISTENING TCP [::]:49171 [::]:0 LISTENING TCP [::]:49186 [::]:0 LISTENING

C:\Windows\system32>

Well your issue isn't that you have another web server running on port 80. Of course there possible issues.

Still trying to resolve this but it doesn't look good. So I was investigating alternatives to XAMPP. I found a few but before I pursue them can anyone tell me how it will impact the PHP classes at Treehouse.

thanks

Don

Any PHP hosting will work, you can use cloud9 cloud hosting or Turn Key Linux LAMP VM or WAMP (which is like XAMPP).

Personally I recommend using cloud9.

thanks,

Yesterday, I installed easyPHP. and everything has been running fine. I have several systems and plan to try cloud9 when I get a chance.

thanks for your help.