CentOS6.2下安装wordpress
- [[email protected] ~]# rpm -ivh http://mirrors.ustc.edu.cn/fedora/epel/6/i386/epel-release-6-8.noarch.rpm //安装EPEL的rpm包
- Retrieving http://mirrors.ustc.edu.cn/fedora/epel/6/i386/epel-release-6-8.noarch.rpm
- warning: /var/tmp/rpm-tmp.ehFT0T: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
- Preparing... ########################################### [100%]
- 1:epel-release ########################################### [100%]
-
[[email protected] ~]# yum --enablerepo=epel -y install wordpress //安装wordpress
###########################省略部分内容#####################################
Installing : php-common-5.3.3-14.el6_3.i686 1/13 - Installing : php-mbstring-5.3.3-14.el6_3.i686 2/13
- Installing : php-xml-5.3.3-14.el6_3.i686 3/13
- Installing : php-pdo-5.3.3-14.el6_3.i686 4/13
- Installing : php-IDNA_Convert-0.8.0-1.el6.noarch 5/13
- Installing : php-simplepie-1.3.1-3.el6.noarch 6/13
- Installing : php-PHPMailer-5.2.2-1.el6.noarch 7/13
- Installing : php-mysql-5.3.3-14.el6_3.i686 8/13
- Installing : php-enchant-5.3.3-14.el6_3.i686 9/13
- Installing : php-cli-5.3.3-14.el6_3.i686 10/13
- Installing : php-5.3.3-14.el6_3.i686 11/13
- Installing : php-process-5.3.3-14.el6_3.i686 12/13
- Installing : wordpress-3.5.1-2.el6.noarch 13/13
- Unable to connect to dbus
- Installed:
- wordpress.noarch 0:3.5.1-2.el6
- Dependency Installed:
- php.i686 0:5.3.3-14.el6_3
- php-IDNA_Convert.noarch 0:0.8.0-1.el6
- php-PHPMailer.noarch 0:5.2.2-1.el6
- php-cli.i686 0:5.3.3-14.el6_3
- php-common.i686 0:5.3.3-14.el6_3
- php-enchant.i686 0:5.3.3-14.el6_3
- php-mbstring.i686 0:5.3.3-14.el6_3
- php-mysql.i686 0:5.3.3-14.el6_3
- php-pdo.i686 0:5.3.3-14.el6_3
- php-process.i686 0:5.3.3-14.el6_3
- php-simplepie.noarch 0:1.3.1-3.el6
- php-xml.i686 0:5.3.3-14.el6_3
- [[email protected] ~]# mysql -u root -p //连接mysql数据库
- Enter password:
- Welcome to the MySQL monitor. Commands end with ; or \g.
- Your MySQL connection id is 4
- Server version: 5.1.67 Source distribution
- Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
- This software comes with ABSOLUTELY NO WARRANTY. This is free software,
- and you are welcome to modify and redistribute it under the GPL v2 license
- Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
- //创建wordpress的数据库
- mysql>create database wordpress character set utf8 collate utf8_bin;
- Query OK, 1 row affected (0.00 sec)
- mysql>grant all privileges on wordpress.* to [email protected]'localhost' identified by 'password';
- Query OK, 0 rows affected (0.00 sec)
- mysql>flush privileges;
- Query OK, 0 rows affected (0.00 sec)
- mysql>exit
- Bye
- [[email protected] ~]# vim /etc/wordpress/wp-config.php //修改wordpress的配置文件
- # line 19: specify database
- define('DB_NAME', 'wordpress');
- # line 22: specify DB user
- define('DB_USER', 'wordpress');
- # line 25: specify DB password
- define('DB_PASSWORD', 'password');
- # line 72: specify your language
- define('WPLANG', 'zh_CN');
- [[email protected] ~]#mkdir /usr/share/wordpress/wp-content/languages
- [[email protected] ~]#wget -P /usr/share/wordpress/wp-content/languages \
- http://svn.automattic.com/wordpress-i18n/zh_CN/tags/3.1.2/messages/zh_CN.mo \
- http://svn.automattic.com/wordpress-i18n/zh_CN/tags/3.1.2/messages/continents-cities-zh_CN.mo
- //下载支持对应的语言,这里是中文
- [[email protected] ~]#/etc/init.d/httpd restart //重启httpd服务
- Stopping httpd: [ OK ]
- Starting httpd: [ OK ]
转载于:https://blog.51cto.com/laoxu/1148420