Saturday 29 June 2013

In Windows 7 How to Install and configure PHP, MYSQL, APACHE Server. 


Now I am going to explain " How to Install and Configure PHP, MYSQL, APACHE server on windows 7 operating system". It is very simple. But for the beginners if not done with care then it would be a night mare for them. I'll clearly depict the scenario. Just follow these steps.

Installing APACHE SERVER: 

To Install this software, first we have to download this we can get this software from below link:
But downloading the required file from the given page is also tedious task.
I'll give you a little clarity here:  Just download it from here.
Don't panic. yes, It's a Zip file doesn't look like normal software installation setup.wait,  I'll Mention what are the things you have to do next. OK, now
  1. Unzip the the downloaded file, it will create a folder with name httpd-2.4.3-win32-ssl_0.9.8.
  2. Copy the contents in the file Apache24.
  3. Now in the C Drive, Create a folder with name webserver.
  4. In that webserver folder create a folder Apache and paste the Contents of Apache24.
  5. In the same webserver folder, create a new folder with name www.
  6. Now the editing tasks starts, Try to figure out the file httpd.conf in C:\webserver\Apache\httpd.conf.
Changes we have to do are
At line 32 Modify the Server root Path (path of Apache Folder). Here in my case it is,
ServerRoot "c:/Apache24" 
as
ServerRoot "c:/webserver/Apache"
At line 237, 238 Modify (Path of www folder)
DocumentRoot "c:/Apache24/htdocs"
<Directory "c:/Apache24/htdocs">
as
DocumentRoot "c:/webserver/www"
<Directory "c:/webserver/www">
At line 258 Modify
AllowOverride None 
as
AllowOverride All
Now save the httpd.conf file. It's the time to test our Apache Installation. 
In the www folder create a sample html page like index.html
let us code it as
<html>
<title>
evignan4u Guide to Apache Installation
</title>
<body>
<br><h1> It's done</h1>
</body>
</html>
copy the above code and save it in index.html
Now open the command prompt and execute the following commands
Note: Run the Command prompt as Administrator else it will displays error message like this.
"AH00369: Failed to open the WinNT service manager, perhaps you forgot to log in as Administrator?" 

Changing the path the Apache bin directory.
cd C:\webserver\Apache\bin 

Install Apache as a service.
httpd.exe -k install

Now run the service by typing following command.
httpd.exe 

It will pop a window and allow access to it.
While running this command you may see one warning message like this:
AH00558: httpd.exe: Could not reliably determine the server's fully qualified do main name, using fe80::d8cd:fa63:d1e9:6083. Set the 'ServerName' directive globa lly to suppress this message
Don't Panic. It's just a error message and it's not going to do any thing.
If you try to change the domain name at line 213 then it will lead to following error
ERROR: 
H00558: httpd: Could not reliably determine the server's fully qualified domai 
d1c:848a:3498:56c4. Set the 'ServerName' directive globally to suppress this me 
(OS 10048)Only one usage of each socket address (protocol/network address/port) 
d. : AH00072: make_sock: could not bind to address [::]:80 
(OS 10048)Only one usage of each socket address (protocol/network address/port) 
d. : AH00072: make_sock: could not bind to address 0.0.0.0:80 
AH00451: no listening sockets available, shutting down 
AH00015: Unable to open logs
So, Don't do it.
Now, We have completed the Installation of Apache.
Now open the browser and type http://localhost
If You can see the Message "It' done" then it's OK and Apache Installed on your computer successfully.
else go through the process one more time carefully or leave a comment below.

No comments:

Post a Comment