Installing amp
Apt-get Install apache2 mysql-server php5 php5-mysql5
Configure Apache2 Default Site
Vi/etc/apache2/sites-enabled/000-default
Join a row
Redirectmatch ^/$/apache2-default/
Testing this step does not require
Modifying the Apache2 master configuration
Vi/etc/apache2/apache2.conf
To change to:
Include Module Configuration:
Include/etc/apache2/mods-enabled/*.load include/etc/apache2/mods-enabled/*.conf
And also:
AddType application/x-httpd-php. php
AddType Application/x-httpd-php-source. Phps
Restart Apache2
/etc/init.d/apache2 Reload
Now to configure PHP 5
Vi/etc/php5/apache2/php.ini
PHP5 default does not support Mysql, in order to open support, to modify
Extension=mysql.so
Set Mysql root Password
The default installation of Mysql, its root user does not have password, is really dangerous, we add a password for him.
Mysqladmin-uroot Password abc123
Where abc123 is your password.
Of course you can also use the following command to set the password:
Mysql-u Root MySQL
mysql> Update user set Password=password (pass) where user=root;
Build a library and its users for the site that will be erected
Mysql-u root-p MySQL
mysql> CREATE DATABASE Drupal;
mysql> use Drupal;
Mysql> Grant all on drupal.* to Drupal_user@localhost;
mysql> use MySQL;
Database changed
mysql> Update user set Password=password (pass) where user = Drupal_user;
Query OK, 1 row Affected (0.00 sec)
Rows matched:1 changed:1 warnings:0
mysql>q;
Mysqladmin Reload
http://www.bkjia.com/PHPjc/531671.html www.bkjia.com true http://www.bkjia.com/PHPjc/531671.html techarticle Install amp apt-get install apache2 mysql-server php5 php5-mysql5 Configure Apache2 default site Vi/etc/apache2/sites-enabled/000-default Join a row redirectmatch ^/$/apache2-defaul ...