?
Solved

Apache Server 2.2 cannot start

Posted on 2011-10-21
4
Medium Priority
?
3,091 Views
Last Modified: 2012-08-14
I try to troubleshoot with:
C:\Program Files(x86)\Apache Software Foundation\Apache2.2\bin>httpd.exe -k start

httpd.exe: Syntax error on line 495 of C:/Program Files(x86)/Apache Software Fo
undation/Apache2.2/conf/httpd.conf: Cannot load C:/Program Files(x86)/Apache So
ftware Foundation/Apache2.2/php5apache2_2.dll into server: The specified module
could not be found.

My softwares installed are:
httpd-2.2.21-win32-x86-no_ssl.msi
php-5.2.17-Win32-VC6-x86.msi

My Error logs are:
apache dir/bin/httpd.exe
>>Error:
C:\Program Files (x86)\Apache Software Foundation\Apache2.2\bin>httpd.exe
httpd.exe: Syntax error on line 495 of C:/Program Files (x86)/Apache Software Fo
undation/Apache2.2/conf/httpd.conf: Cannot load C:/Program Files (x86)/Apache So
ftware Foundation/Apache2.2/php5apache2_2.dll into server: The specified module
could not be found.

apache dir/log/error.log
>>
[Thu Oct 20 17:55:54 2011] [warn] pid file C:/Program Files (x86)/Apache Software Foundation/Apache2.2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Thu Oct 20 17:55:54 2011] [notice] Apache/2.2.21 (Win32) configured -- resuming normal operations
[Thu Oct 20 17:55:54 2011] [notice] Server built: Sep  9 2011 10:26:10
[Thu Oct 20 17:55:54 2011] [notice] Parent: Created child process 2128
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Thu Oct 20 17:55:54 2011] [notice] Child 2128: Child process is running
[Thu Oct 20 17:55:54 2011] [notice] Child 2128: Acquired the start mutex.
[Thu Oct 20 17:55:54 2011] [notice] Child 2128: Starting 64 worker threads.
[Thu Oct 20 17:55:54 2011] [notice] Child 2128: Starting thread to listen on port 80.
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Thu Oct 20 22:48:56 2011] [warn] pid file C:/Program Files (x86)/Apache Software Foundation/Apache2.2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Thu Oct 20 22:48:56 2011] [notice] Apache/2.2.21 (Win32) configured -- resuming normal operations
[Thu Oct 20 22:48:56 2011] [notice] Server built: Sep  9 2011 10:26:10
[Thu Oct 20 22:48:56 2011] [notice] Parent: Created child process 1296
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Thu Oct 20 22:48:57 2011] [notice] Child 1296: Child process is running
[Thu Oct 20 22:48:57 2011] [notice] Child 1296: Acquired the start mutex.
[Thu Oct 20 22:48:57 2011] [notice] Child 1296: Starting 64 worker threads.
[Thu Oct 20 22:48:57 2011] [notice] Child 1296: Starting thread to listen on port 80.
[Thu Oct 20 23:16:01 2011] [notice] Parent: Received shutdown signal -- Shutting down the server.
[Thu Oct 20 23:16:01 2011] [notice] Child 1296: Exit event signaled. Child process is ending.
[Thu Oct 20 23:16:02 2011] [notice] Child 1296: Released the start mutex
[Thu Oct 20 23:16:03 2011] [notice] Child 1296: All worker threads have exited.
[Thu Oct 20 23:16:03 2011] [notice] Child 1296: Child process is exiting
[Thu Oct 20 23:16:03 2011] [notice] Parent: Child process exited successfully.


Many thanks

Rgds,

yjchong514
0
Comment
Question by:yjchong514
  • 3
4 Comments
 
LVL 19

Accepted Solution

by:
xterm earned 2000 total points
ID: 37008331
You need to do a file search to locate where php5apache2_2.dll got installed on your system and then edit httpd.conf on line 495 to have the exact path to where it was installed.  Right now it's looking for:

C:/Program Files (x86)/Apache Software Foundation/Apache2.2/php5apache2_2.dll

I haven't used Windows in a while, but it seems to me those should all be backslashes, not forward slashes.  Not sure if Apache is smart enough to reverse them back into Windows paths or not, but I doubt it.

0
 
LVL 6

Author Comment

by:yjchong514
ID: 37010128
File search show that I have php5apache2_2.dll in:
C:\Program Files (x86)\PHP\php5apache2_2.dll

I have this in line 495:
#BEGIN PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL
PHPIniDir ""
LoadModule php5_module "php5apache2_2.dll"   <-Line 495
#END PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL

Any advice ?

TQ

Regards,
yjchong514
0
 
LVL 6

Author Comment

by:yjchong514
ID: 37010155
Yes. It works now after I refer to:
http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Q_22423685.html?sfQueryTermInfo=1+10+30+loadmodul+php5_modul+php5apache2_2.dl

I need to add C:\Program Files (x86)\PHP\ where php.ini located into PHPIniDir "C:\Program Files (x86)\PHP\ "

and

modify LoadModule php5_module "php5apache2_2.dll"
into
LoadModule php5_module "C:\Program Files (x86)\PHP\php5apache2_2.dll"

Then my Apache Server will start service successfully.

Thanks!!!
Wish you have a good weekend !

Regards,

yjchong514
0
 
LVL 6

Author Closing Comment

by:yjchong514
ID: 37010159
Your explaination is clear and you are a good helper.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction As you’re probably aware the HTTP protocol offers basic / weak authentication, which in combination with the relevant configuration on your web server, provides the ability to password protect all or part of your host.  If you were not…
If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Suggested Courses
Course of the Month14 days, 5 hours left to enroll

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question