After a year, again installed apache+php, loaded with PHP and a new understanding.
Last year when it was installed, I wrote notes: http://blog.csdn.net/monkey7777/article/details/9261325.
Refer to the notes above for a detailed configuration lesson.
Now write down some of the problems that may occur during the installation:
1. Start Apache encountered error: Httpd:could not reliably determine the server ' s fully qualified domain name
My understanding of this problem is: port problem. (Port occupancy, port conflicts, similar issues)
One way to find "Listen" in Apache's httpd.conf file is to modify its port value.
Another approach is to find the process that is currently occupying the port and kill the process.
Find Port Usage:
Netstat-anofindstr "8080"
To view the processes that use this port: ("X" is the process number)
Tasklistfindstr "X"
End a process: ("X" is the process number)
Tskill "X"
Given my Tomcat's port 8088,iis 8080, I changed the listen value to 8090 to solve the problem.
If none of the above methods are resolved (should be a problem with DNS configuration), you can add a sentence in httpd.conf (add "ServerName localhost:8090" at the following location):
#ServerName www.example.com:80
ServerName localhost:80
2. Start Apache prompt error "Cannot load Php5apache2_4.dll into server"
I downloaded the latest version of PHP (php-5.5.15-win32-vc11-x64).
In httpd.conf, there is a sentence: (Show this line error when it is wrong)
LoadModule php5_module "C:\php\php5apache2_4.dll"
The first idea to see the problem was to replace Php5apache2_4.dll with Php5apache2_2.dll, which proved unsuccessful.
Online search, the reason can be understood as: version of the problem.
Be careful, you will find that PHP name will have a VC9,VC11 logo. Represents the PHP should run in what kind of VC compiler environment. (After all, this thing practical C + + written ...) )
My understanding is that with VC9 should be run under the VC2008 runtime, VC11 should be installed under the VC2012 Run library. However, I have installed 2012 of the runtime and found that it still does not run correctly. Use the light God to the php-5.3.6-win32-vc9-x64 (inside is Php5apache2_2.dll), configure well after running OK.
http://windows.php.net/'s website is like saying:
VC9 and VC11 more
recent versions to PHP are built with VC9 or VC11 (Visual Studio 2008 and compiler ) and include improvements in performance and stability.
The VC9 builds require you to have the Visual C + + redistributable for Visual Studio 2008 SP1 or x86 x64.
The VC11 builds require to have the Visual C + + redistributable for Visual Studio x86 or x64.
It means that VC9 and VC11 each need a specific compilation environment. VC9--> vc2008,vc11--> VC2012.
On the internet to see such a statement. "Because of the different versions of Apache, the corresponding" Php5apache2.dll "are different. It means that the Apache and PHP versions have a complementary relationship.
That
Apache2.2 corresponds to Php5apache2_2.dll
Apache2.1 corresponding php5apache2.dll
Apache1 corresponding Php5apache.dll
But I think there should be no corresponding relationship, after all, the official network did not say well.
But I installed the VC2012 runtime VC11 version of PHP is not easy to use, I can only suspect that I VC2012 the runtime is not installed or there is really a corresponding relationship.
If the environment is no problem, this correspondence may as well try.