XAMPP Not working | HTTP Error 404 (Win7) 1.7.7 [SOLVED]

Problems with the Windows version of XAMPP, questions, comments, and anything related.

XAMPP Not working | HTTP Error 404 (Win7) 1.7.7 [SOLVED]

Postby Synthologic » 07. November 2011 08:18

Hello everyone!

I am using Windows 7 Professional 32Bit and XAMPP 1.7.7

I cannot get XAMPP or should I say my PHP pages to work.
When I preview a PHP page in a browser I get the following message.

HTTP Error 404. The requested resource is not found.

I have Microsoft Security Essentials Installed and Windows Firewall activated

I changed the port number in the httpd.conf file from 80 to 8080. My first thought was to avoid port conflict
with Windows Firewall.

This issue has never happened before, today I uninstalled Norton Internet Security and installed Microsoft Security Essentials. I also installed
SQL Server 2008 Standard R2. Before than, it worked perfectly. I also have SQL Server 2008 and Microsoft Security Essentials on my other computer and this is not happening.

Can anyone help please.
Synthologic
 
Posts: 5
Joined: 07. November 2011 07:56
Operating System: Windows 7 Professional 32Bit

Re: XAMPP Not working | HTTP Error 404.

Postby Sharley » 07. November 2011 08:25

There was no need to change ports and may I suggest you return the httpd.conf file back to it's default settings.

Are there any clues in the \xampp\apache\logs\error.log file?

What are you typing in your browser?

I assume that Apache and MySQL are both running?

Exit the older 2.5 Control Panel and use the new xampp-control-3-beta.exe found in the xampp folder, it has better error reporting and creates a log file also in the xampp folder.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: XAMPP Not working | HTTP Error 404.

Postby JonB » 07. November 2011 15:28

This is likely the culprit:

I also installed SQL Server 2008 Standard R2


Most MS Server products use agents on port 80 for their Web Administration interface.

Take a look here:
viewtopic.php?f=16&t=40062&p=166538&hilit=+SQL+Server+2008+#p166538

Good Luck
8)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: XAMPP Not working | HTTP Error 404.

Postby Synthologic » 08. November 2011 06:47

Sharley wrote:There was no need to change ports and may I suggest you return the httpd.conf file back to it's default settings.

Are there any clues in the \xampp\apache\logs\error.log file?

What are you typing in your browser?

I assume that Apache and MySQL are both running?

Exit the older 2.5 Control Panel and use the new xampp-control-3-beta.exe found in the xampp folder, it has better error reporting and creates a log file also in the xampp folder.


I am simply trying to view the php pages saved in the server folder. I have used XAMPP for years to develop PHP web pages.

Thanks for responding, I changed the ports back to 80.

Here is the error log:

[Mon Nov 07 00:50:35 2011] [notice] Digest: generating secret for digest authentication ...
[Mon Nov 07 00:50:35 2011] [notice] Digest: done
[Mon Nov 07 00:50:37 2011] [notice] Apache/2.2.21 (Win32) mod_ssl/2.2.21 OpenSSL/1.0.0e PHP/5.3.8 mod_perl/2.0.4 Perl/v5.10.1 configured -- resuming normal operations
[Mon Nov 07 00:50:37 2011] [notice] Server built: Sep 10 2011 11:34:11
[Mon Nov 07 00:50:37 2011] [notice] Parent: Created child process 5688
[Mon Nov 07 00:50:38 2011] [notice] Digest: generating secret for digest authentication ...
[Mon Nov 07 00:50:38 2011] [notice] Digest: done
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Child process is running
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Acquired the start mutex.
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Starting 150 worker threads.
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Starting thread to listen on port 443.
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Starting thread to listen on port 8080.
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Starting thread to listen on port 443.
[Mon Nov 07 00:50:40 2011] [notice] Child 5688: Starting thread to listen on port 8080.
[Mon Nov 07 00:53:10 2011] [warn] pid file c:/xampp/apache/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Mon Nov 07 00:53:10 2011] [notice] Digest: generating secret for digest authentication ...
[Mon Nov 07 00:53:10 2011] [notice] Digest: done
[Mon Nov 07 00:53:12 2011] [notice] Apache/2.2.21 (Win32) mod_ssl/2.2.21 OpenSSL/1.0.0e PHP/5.3.8 mod_perl/2.0.4 Perl/v5.10.1 configured -- resuming normal operations
[Mon Nov 07 00:53:12 2011] [notice] Server built: Sep 10 2011 11:34:11
[Mon Nov 07 00:53:12 2011] [notice] Parent: Created child process 5712
[Mon Nov 07 00:53:14 2011] [notice] Digest: generating secret for digest authentication ...
[Mon Nov 07 00:53:14 2011] [notice] Digest: done
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Child process is running
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Acquired the start mutex.
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Starting 150 worker threads.
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Starting thread to listen on port 443.
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Starting thread to listen on port 443.
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Starting thread to listen on port 8080.
[Mon Nov 07 00:53:15 2011] [notice] Child 5712: Starting thread to listen on port 8080.


Thanks again!
Synthologic
 
Posts: 5
Joined: 07. November 2011 07:56
Operating System: Windows 7 Professional 32Bit

Re: XAMPP Not working | HTTP Error 404.

Postby Sharley » 08. November 2011 07:02

@JonB
The link on the page you referred to gives me a 'Failed to load page content' error. :shock:

Synthologic wrote:I changed the ports back to 80.
The log file still has Apache listening on port 8080 - did you restart Apache after editing the conf file back to port 80?

The log file has no record of a file not found 404 error which it should have.

Where exactly did you store your php files on the server...

...and what are you now typing in your browser when you get the 404 error?

What did the log file of the new CP3 contain when you tried to start Apache and MySQL?

I really need these questions answered so I can get a picture of what you see that I can't so that I may be able to find a solution for this mystery file not found 404 error.
Thanks.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: XAMPP Not working | HTTP Error 404.

Postby Synthologic » 08. November 2011 07:12

Sharley wrote:
Synthologic wrote:I changed the ports back to 80.
The log file still has Apache listening on port 8080 - did you restart Apache after editing the conf file back to port 80?

The log file has no record of a file not found 404 error which it should have.

Where exactly did you store your php files on the server...

...and what are you now typing in your browser when you get the 404 error?

What did the log file of the new CP3 contain when you tried to start Apache and MySQL?


Yes I started XAMPP with the new Control Panel:
Here is the start up message from the panel.

12:06:38 AM [main] Initializing main
12:06:38 AM [main] Windows version: 6.1 (build 7601) - Service Pack 1
12:06:38 AM [main] Xampp version: 1.7.7
12:06:38 AM [main] Control center version: 3.0.2 [ Compiled: Jul 21th 2011 - build #1 ]
12:06:38 AM [main] Running as admin - good!
12:06:38 AM [main] Working with basedir: "c:\xampp\"
12:06:38 AM [main] Initializing moduls
12:06:38 AM [apache] Possible problem detected: Port 80 in use by "system"!
12:06:38 AM [main] Starting check-timer

And here is the httpd.conf showing port 80
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 0.0.0.0:80
#Listen [::]:80
Listen 80


The files are stored in the htdocs folder and I am simply typing the http//localhost/whatever_page.php
Synthologic
 
Posts: 5
Joined: 07. November 2011 07:56
Operating System: Windows 7 Professional 32Bit

Re: XAMPP Not working | HTTP Error 404.

Postby Sharley » 08. November 2011 07:29

The 'system' using port 80 can be one of 2 things - as suggested earlier the installation of the SQL server has an agent using port 80 and so if possible temporarily disable this or have the SQL server agent listen on a different port than port 80 (Microsoft seems to prefer that you use their $$$ products rather than a free Apache server and so seems to like hogging port 80 when ever it can)

The other could be that you are have installed the service module for Apache and MySQL (a green tick in the CP3 service module column).
If possible try and remove the ticks and answer the question when asked.

If it is not possible to remove the ticks then in CP3 there is a Win-service button and when pressed will go to the Service Controller where you can Start or Stop Apache2.2 then when you return to the CP3 you may be able to start Apache.

Also in the Service Controller you may be able to find the SQL server entry listed and perhaps be able to disable it for now.

There is a conflict with port 80 and if possible it is best to disable what ever is using the web server default port 80 as if you change the Listen port then this can lead to possible issues down the track.


Without a 404 log file entry it will be hard to solve your 404 issue but after we get Apache using port 80 then it may be that there will be a log file entry.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: XAMPP Not working | HTTP Error 404.

Postby Synthologic » 08. November 2011 07:35

Sharley wrote:The 'system' using port 80 can be one of 2 things - as suggested earlier the installation of the SQL server has an agent using port 80 and so if possible temporarily disable this or have the SQL server agent listen on a different port than port 80 (Microsoft seems to prefer that you use their $$$ products rather than a free Apache server and so seems to like hogging port 80 when ever it can)

The other could be that you are have installed the service module for Apache and MySQL (a green tick in the CP3 service module column).
If possible try and remove the ticks and answer the question when asked.

If it is not possible to remove the ticks then in CP3 there is a Win-service button and when pressed will go to the Service Controller where you can Start or Stop Apache2.2 then when you return to the CP3 you may be able to start Apache.

Also in the Service Controller you may be able to find the SQL server entry listed and perhaps be able to disable it for now.

There is a conflict with port 80 and if possible it is best to disable what ever is using the web server default port 80 as if you change the Listen port then this can lead to possible issues down the track.


Without a 404 log file entry it will be hard to solve your 404 issue but after we get Apache using port 80 then it may be that there will be a log file entry.


I am not sure what question you are asking but I'll explain what I have done:

To create dynamic pages with PHP and Dreamweaver.

Here is a link by David Powers that shows exactly how I set up Dreamweaver using XAMPP.
If you will scroll down you will see screen shots:
http://www.adobe.com/devnet/dreamweaver ... p_php.html

Also I am not running Apache/XAMPP as a service. The ticks or checks are unmarked.

Thanks for your help!

Synth
Synthologic
 
Posts: 5
Joined: 07. November 2011 07:56
Operating System: Windows 7 Professional 32Bit

Re: XAMPP Not working | HTTP Error 404.

Postby Sharley » 08. November 2011 08:01

The 404 error when you had the Listen port on 8080 may have been caused by not appending the port number to the address like so:
http://localhost:8080/whatever_page.php

A good reason to have Apache listen on port 80 if possible as you can see now that this 8080 port number has to be appended to every URL that you use and could be a real issue in future - even in DW this appending of the port number applies.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: XAMPP Not working | HTTP Error 404.

Postby Synthologic » 08. November 2011 08:11

Sharley wrote:The 404 error when you had the Listen port on 8080 may have been caused by not appending the port number to the address like so:
http://localhost:8080/whatever_page.php

A good reason to have Apache listen on port 80 if possible as you can see now that this 8080 port number has to be appended to every URL that you use and could be a real issue in future.


I have it working now.

I went into Windows Services and stopped SQL Server Reporting services.

Now I do not know how this is going to affect SQL Server.

Any idea?

And here is my link to my test page. Note, I change the directoy in the httpd.conf file.

http://localhost/my_folder/test.php
and here is the directory: <Directory "N:/developer/">

Thanks again!

Synth
Synthologic
 
Posts: 5
Joined: 07. November 2011 07:56
Operating System: Windows 7 Professional 32Bit

Re: XAMPP Not working | HTTP Error 404.

Postby Sharley » 08. November 2011 08:19

Your welcome and thanks for the feedback. 8)

That's good news that you now have Apache on port 80 and you can access your php pages without issue and seemingly all is working and you can move forward. :)

Sorry I know absolutely nothing about SQL Server and so can't suggest a solution to it's use of port 80 but this link may help:
http://www.sql4you.com/?p=196
This will allow you to have both Apache and SQL Server running at the same time.

Or try these Google search results.

Good luck and best wishes. :)
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 123 guests