Linux under Aphche Preparation tutorial (Center Os)

Source: Internet
Author: User

A few days ago replaced a server, re-equipped with a Web server, the approximate process is as follows (due to idle compilation comparison annoying lock, so the direct Yum installation):

I. Installing the Web server Software yum install httpd

Two. Install the PHP yum install php* yum-y install php*--skip-broken

Three. installing MySQL yum install mysql*

Four. After the above three steps, has completed the Apache, PHP, MySQL installation, then directly simple configuration can be

(1) Preparation site vim/etc/httpd/conf/httpd.conf

Add a site:

Namevirtualhost 127.0.0.1:80
<virtualhost 127.0.0.1:80>
ServerName http://www.aaa.com
DocumentRoot "/DATA/WWW/AAA"
<directory "/data/www/aaa/" >
Options followsymlinks includesnoexec Indexes
DirectoryIndex index.php index.html index.shtml
AllowOverride All
Order Deny,allow
Allow from all
</Directory>
</VirtualHost>

(2) Add Apache to the list of Linux services to enable the operation of Apache startup, restart, and shutdown through service.

Chkconfig–-add httpd

Chkconfig httpd on

Extended reading: chkconfig command Details (Linux)

(3) Restart Apache NINGX service httpd restart

Linux under Aphche Preparation tutorial (Center Os)

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.