The Apache service cannot start multiple methods summary?

Source: Internet
Author: User
Tags apache error log socket win32 fully qualified domain name

Unable to start a

One thought, a few days ago installed XAMPPP, is not squeezed out, immediately ran to the service of a look, nothing, both services are not. Try Xampp and start. Native Apache is not start, service does not exist!
Internet search data, are said to be 80 port is occupied, immediately netstat-aon|findstr "80", a look at 1388 occupy 80, but this is the Firefox browser ... You can't use a browser. This is obviously wrong. Since the service does not exist, the solution should be to install the service.

Immediately, install the service.
Enter Apache Bin directory, command line interface run httpd, execute httpd-k install-n "Apache", install Apache service, command line gives the following prompt:
Could not reliably determine the server's fully qualified domain name, using 192.168.5.201 for ServerName.
Good to do, open httpd.conf configuration file, add ServerName localhost:80, and then rerun ApacheMonitor.exe, OK. Look at the previous backup configuration file, this line is commented out. It's not clear why you used to do it before and then install other integration kits. Apache configuration also familiar with the ha.
----------------------There is one more situation---------------

Start Apache. But the start time but the error, cannot reboot. View Apache error log file, showing unclean shutdown of previous Apache run?

To search the Internet, there are generally two kinds of error probability:

First: [warn] pid file d:/apache2.2/logs/httpd.pid overwritten-unclean shutdown of previous Apache run?

The corresponding Apache PID file needs to be deleted. But that's not what most people come across.

In the second case, the PHP module adds an error. For example, DLL files are not in accordance with the provisions of the Php/ext directory, such as php.ini file writing errors. If nothing is found, try removing the newly added module and trying it out. The biggest possibility is that the new extensions are incompatible with the PHP version, and the extension cannot be found.
You can run the Php.exe to test, if it is an extension of the problem, will play window prompts.


Apache Service failed to start prompt service started and stopped

System: Windows XP Professional Service Pack2
WAMP5 Integrated installation package
Test 80 Port display: "Your port is not actually used." (Even if you change the Apache port to 8080, it won't start)
The error log is as follows:

--------------------------------------------------------------------------------------
[Fri Nov 26 10:43:26 2010] [Notice] Server Built:jan 18 2008 00:37:19
[Fri Nov 26 10:43:26 2010] [Notice] parent:created Child Process 1060
[Fri Nov 26 10:43:26 2010] [Notice] Child 1060:child process is running
[Fri Nov 26 10:43:26 2010] [Crit]  (OS 10022) provides an invalid parameter. : Child 1060:setup_inherited_listeners (), WSASocket failed to open the inherited socket.
[Fri Nov 26 10:43:27 2010] [Crit] Parent:child process exited with status 3-aborting.
[Fri Nov 26 10:44:57 2010] [Notice] apache/2.2.8 (WIN32) php/5.2.6 configured--Resuming normal operations
[Fri Nov 26 10:44:57 2010] [Notice] Server Built:jan 18 2008 00:37:19
[Fri Nov 26 10:44:57 2010] [Notice] parent:created Child Process 6100
[Fri Nov 26 10:44:58 2010] [Notice] Child 6100:child process is running
[Fri Nov 26 10:44:58 2010] [Crit]  (OS 10022) provides an invalid parameter. : Child 6100:setup_inherited_listeners (), WSASocket failed to open the inherited socket.
[Fri Nov 26 10:44:58 2010] [Crit] Parent:child process exited with status 3-aborting.
[Fri Nov 26 10:45:50 2010] [Notice] apache/2.2.8 (WIN32) php/5.2.6 configured--Resuming normal operations
[Fri Nov 26 10:45:50 2010] [Notice] Server Built:jan 18 2008 00:37:19
[Fri Nov 26 10:45:50 2010] [Notice] parent:created Child Process 4180
[Fri Nov 26 10:45:50 2010] [Notice] Child 4180:child process is running
[Fri Nov 26 10:45:50 2010] [Crit]  (OS 10022) provides an invalid parameter. : Child 4180:setup_inherited_listeners (), WSASocket failed to open the inherited socket.
[Fri Nov 26 10:45:50 2010] [Crit] Parent:child process exited with status 3-aborting.
[Fri Nov 26 10:49:46 2010] [Notice] apache/2.2.8 (WIN32) php/5.2.6 configured--resuming
---------------------------------------------------------------------------------------
Uninstall this installation package n times and delete every time, and the residual service in the registry is also removed clean, and the n times, still can not start the Apache service (this installation package in the Internet bar can be installed and used properly).

After a network search and our technician discussion and exploration, finally found a solution:
Local Area Connection---properties----Internet protocol (TCP/IP)---Properties---advanced---wins----import lmhosts (M) Add {Apache2dir}binhttpd.exe to the start

For example: Httpd.exe path is "F:wamp2binapacheapache2.2.8binhttpd.exe", then {apache2dir} is "f:wamp2binapacheapache2.2.8"

Configuring the Apache service under Windows systems sometimes encounters

The Apache2 service failed to start.

A service-specific error occurred: 1.

Please type NET helpmsg 3547 for more help.

Error, this error can be caused by a number of reasons. I found out today that the profile comments are not working well. Also a reason for this error: If a comment is written in the profile httpd.conf, the comment must be placed on a single line as the # begins. A # annotation is written on the same line as a configuration item, which can cause problems that cannot be started. The solution is to put the annotations on one line alone. This is just one possible reason for not being able to start


Service can be started but input localhost cannot open page

This is typically caused by a NetBIOS parsing failure. The solution is simple, and the steps are as follows:
1 Right click on "My Network Places" and choose "Properties (R)" on the menu. Out of the Network Connections window, right-click on Local Area Connection, menu Midpoint property (R). Out of the Local Area Connection properties panel, found in this link using the following items: Internet protocol (TCP/IP), and click it. On the Internet Protocol (TCP/IP) properties panel that pops up, click the Advanced (V) ... button. On the Advanced TCP/IP Settings panel, click the WINS tab, and remove the check in front of the Enable LMHOSTS query (L), and click OK.
2 Open "Control Panel", click "Windows Firewall", click "Advanced" tab, select "Local Connection" and click Next to "Set (T) ..." button. Locate secure Web Server (HTTPS) in the service option and tick it up, click OK.

Last type of problem PHP file cannot be resolved
When you are surprised to find that you can open http://localhost and see Apache's "IT works!" The page, you are very excited to test a phpnifo immediately, but found that unable to parse. This is because Apache doesn't know how to parse php files. Although the LoadModule and AddType statements have told Apache to load the PHP module and note the php suffix file, the real parsing is to call Php5ts.dll and so on, so
Scenario One: Add PHP directory in path and add in httpd.conf
Phpinidir "d:/php-5.2.5-win32/"
Scenario Two: Directly copy the Php5ts.dll from the PHP directory to the Apache bin directory

There is also a point to note that apache2.2 above version requires the use of Php5apache2_2.dll
in php5.2.5 has been brought in with the previous version, such as php5.1 please go to http:// php.net Download patch Php5apache2.dll-php5.1.x.rar and unzip. A total of three files.
Vcredist_x86.exe
Php5apache2.dll
httpd.exe.manifest
1. Cover your original PHP directory with Php5apache2.dll Php5apache2.dll files.
2. Copy the Httpd.exe.manifest file to the Bin folder under your Apache installation directory.
3. Double-click to run Vcredist_x86.exe installation. (If the. NET Framework 2 is already installed in your system, you can skip this step)
Finish! Reboot your apache2.2 try it.
of course, using php5.2.5 is completely without the problem!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.