LAMP 是Linux, Apache, MySQL, PHP, perl的縮寫. 指在linux上安裝Apache2镣陕,MySQL, PHP等軟件包所建立的網(wǎng)站運(yùn)行平臺(tái)馋艺,是目前中小網(wǎng)站主要的運(yùn)行環(huán)境。
1.1 安裝Apache2
sudo apt-get install apache2
1.2 安裝MySQL5
sudo apt-get install mysql-server mysql-client
中途需要設(shè)置root密碼
1.3 安裝PHP5
sudo apt-get install php5 libapache2-mod-php5 php5-mysql php5-curl php5-gd php5-intl php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-ming php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl php5-xcache libssh2-php
1.4 安裝phpMyAdmin
sudo apt-get install phpmyadmin
...
Web server to reconfigure automatically: < -- apache2
Configure database for phpmyadmin with dbconfig-common? <-- No
...
- 初始化數(shù)據(jù)庫
sudo mysql -u root -p
Enter Password:
...
mysql> CREATE DATABASE wordpressdb;
mysql> CREATE USER wordpressuser@localhost IDENTIFIED BY '你的密碼';
mysql> GRANT ALL PRIVILEGES ON wordpressdb.* TO wordpressuser@localhost;
mysql> FLUSH PRIVILEGES;
mysql> exit
重啟服務(wù)
sudo service apache2 restart
sudo service mysql restart
- 下載并配置WordPress
$ mkdir temp
$ cd temp
$ wget http://wordpress.org/wordpress-4.x.tar.gz(最新版本號(hào))
$ tar zxf wordpress-4.x.tar.gz -C /var/www/html/
$ mkdir -p /var/www/html/wordpress/wp-content/uploads
轉(zhuǎn)自http://www.cnblogs.com/R0b1n/p/5224070.html
http://blog.csdn.net/ansencumt/article/details/9000436
目前配置wp-config.php