apache,mysql,php installation configuration under Windows

Source: Internet
Author: User

0. Operating system

Windows8.1 x64

1. Installing Apache

Open http://httpd.apache.org left download! point from a Mirror, see the current stable version is not 2.4.12, see now that the version of Windows is not as available as before. msi and. zip download package. Instead, Tip:

Apache httpd for Microsoft Windows are available from a number of third party vendors. Appears to need to be obtained from a third party. Click this link to select the first from the recommended third party: Apachehaus, which can be downloaded to the Windows Zip package,

We chose to download the Httpd-2.4.12-x64-vc11.zip and extract it to the system directory.

Because it is VC11 compiled, our system to install VC11 redistribute, My computer has been installed.

2. Configure Apache

In the Apache extract directory found in the Conf directory of the httpd.conf file, a text editor opened, found

Define srvroot "/apache24"

This is the root directory that defines the Apache service, which is the root directory of your Apache, and if this configuration error is incorrect:

Cannot load modules/mod_actions.so into server: \xd5\xd2\xb2\xbb\xb5\xbd\xd6\xb8\xb6\xa8\xb5\xc4\xc4\xa3\xbf\xe9\ Xa1\xa3

This is because the directory configuration error, the corresponding modules directory can not be found, so the first module to be loaded will be prompted to find.

My system is configured like this:

#Define srvroot "/apache24"
Define srvroot "F:/software/dev/apache/httpd-2.4.12-x64-vc11/apache24"
ServerRoot "${srvroot}"

Configure the Web publishing directory

Search for documentroot, modified to:

#DocumentRoot "${srvroot}/htdocs"
DocumentRoot "e:/php"

Modify Port:

Apache defaults to port 80 because my 80 port program is already in use, we changed to 8080:

Listen 127.0.0.1:8080

ServerName localhost:8080

Install Apache as a service, Run command prompt (CMD) with the administrator ID,

Go to Bin directory, run httpd.exe-k install

If the installation is successful, you can use the ApacheMonitor.exe tool to control the start and stop of the service, we start the Apache service

To prepare the test, put a test.txt file under E:/php, with the contents of Hello, Jsoft, and browser access:

Http://localhost:8080/test.txt

Unexpectedly prompt 403 Error!

Re-open httpd.conf

Locate the root configuration for the publication,

<directory/>
allowoverride None
Require all denied
</Directory>

Modified to:

<directory/>
allowoverride None
#Require all denied
Require all granted
</Directory>

Restart Apache service, refresh http://localhost:8080/test.txt, the browser appears familiar Hello, jsoft

Apache is here to install the configuration successfully, to be used.

< to Be continued >

apache,mysql,php installation configuration under Windows

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.