About PHP Local test environment

Source: Internet
Author: User

Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall

A)

Yesterday on the computer installed Dede local test environment, want to run a few PHP programs to play. The installation process is normal, installation is complete, start Apache, but how can not start. Always started, and inexplicably stopped automatically. I started--> run--> input services.msc into the "service (local)", where manually started, or did not succeed, give a warning box. Tip: The Apache2.2 service on the local computer is started and stopped. Some services automatically stop if they have nothing to do, such as the Performance Logs and Alerts service. I don't know what that means. Went to Google for a while.

The finished solution is published as follows:

Right-click on the Desktop Network Neighborhood--> Click Properties--> Open the Networking window--> on the local Area Connection Right-click Properties--> Open the Local Area Connection Properties dialog box--> under the General tab, this connection uses the following items (o): Double-click Internet Protocol (TCP/IP)--> to open the Internet Protocol (TCP/IP) Properties dialog box--> Click the "Advanced (V) ..." button on the right leg--> to open the Advanced TCP/IP Settings dialog box--> Click the WINS tab--> to select Disable NetBIOS (s) on TCP/IP. --> always click "OK" button.

Two)

These two days do not know why Apache startup when there are always problems, find a lot of methods or not, depressed for several days.

Always prompt when you manually start Apache: The Apache service on the local computer is started and stopped, and some services stop automatically if they have nothing to do, such as the log and alert service.

Today finally solved the problem, the heart more comfortable.

The workaround is as follows:

Select in Network connection properties

TCP/IP Properties--> Advanced-->wins Label---> Below are options for enabling LMHOSTS queries and NetBIOS

Instead, you can immediately see the Apache Process CPU drop quickly (no more attempts to open the Subprocess) in Task Manager

It's been tested for a while.

It might still have something to do with Tcpip.sys's file.

Especially XP SP2 System

The extreme way is to turn off Apache logs.

How do I close the apache2 log file (logfile)? This is a problem because writing a log can cause a great loss to the system. When you close the log, you can even maximize overall performance by nearly 40% (rough estimate) So how do I turn off the log?

You can reduce log reads and writes by reducing the log level.

The caveat here is that doing so will bring trouble to intrusion detection and other work based on log analysis. So please use it with caution.

LogLevel is used to adjust the verbosity of the information that is recorded in the error log. (see errorlog directives). You can select the following levels in descending order of importance:

Level Description Example

Emerg emergency-system unusable. "Child cant open lock file. Exiting "

Alert must take immediate action. ' GETPWUID:COULDN ' t determine user name from UID

Crit fatal condition. "Socket:failed to get a socket, exiting child"

Error condition. "Premature end of script headers"

Warn warning. "Child process 1234 did not exit, sending another Sighup"

Notice is generally important. "Httpd:caught Sigbus, attempting to dump core in ..."

Info General information. "Server seems busy, (you may need to could startservers, or min/maxspareservers) ..."

Debug error level Information "Opening Config file ..."

It is generally recommended that you use Crit to warn settings

Three)

Although the above method solves the problem of Apache, but this will appear occasionally on the network phenomenon. After many days of data search, finally found a more perfect solution, the following methods:

Network Neighborhood->; View the-> local connection (the connection you're using, which is usually the name)->; right click it select "Properties"->; Check Internet Protocol (TCP/IP)

->; Property->; Advanced->; switch to the WINS tab-> Click "Import lmhosts (M)" and then select the Bin folder you installed in the Apache directory (my installed directory is d:\\appserv\\apache2.2\\bin) When you import Httpd.exe, you can turn on Apache and surf the Internet.

But now I do not know why my computer always appear this problem: Find a master to help! After the point of opening the file always appear to format the problem!

In addition, I just made the navigation station: Http://www.chuangtoucn.cn/daohang If you do not have the navigation station to set this homepage AH

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.