Wordpress安装
2015/5/13 12:35:07
实验环境:
主机名 | ip地址 | 操作系统 | 应用角色 |
---|
Linux | 192.168.1.150 | Centos 6.6 | Wordpress |
软件版本:
软件名 | 软件版本 |
---|
Mysql | 5.1.73 |
Wordpress | 4.2 |
一:安装软件
[root@Linux ~]# yum install mysql-server php php-devel httpd
二:更改配置文件及启动相关服务
[root@Linux ~]# sed '/^$/d;/^#/d' /etc/httpd/conf/httpd.conf > /etc/httpd/conf/httpd.conf
[root@Linux ~]# vim /etc/httpd/conf/httpd.conf
//修改访问路径
DocumentRoot "/var/www/html/wordpress"
//添加php环境支持
AddType application/x-httpd-php .php
[root@Linux ~]# service php-fpm restart
[root@Linux ~]# service mysqld restart
[root@Linux ~]# mysqladmin -u root password 'mysql-pass' //给MySQL加密码,并创建worpress数据库,在web设置wordpress需要用
[root@Linux ~]# service httpd restart
三:下载wordpress并安装
[root@Linux ~]# wget https://cn.wordpress.org/wordpress-4.2-zh_CN.tar.gz
[root@Linux ~]# tar zxf wordpress-4.2-zh_CN.tar.gz -C /var/www/html/
[root@Linux ~]# chown -R apache.apache /var/www/html/wordpress/
四:访问wordpress站点并进行相关设置
在浏览器输入即可访问: http://ip/
注:图形化设置不在进行说明,请自行按照显示说明进行设置.