wordpress配置安装

1、首先进行lamp框架的搭建

服务器环境:Linux Centos 7.2.1511 64位

内存:2G 

磁盘空间100GB

IP地址:10.55.10.79

进行httpd,php,php-mysql,mariadb-server的安装,安装均使用yum安装

~]# yum -y install httpd php php-mysql mariadb-server

进行防火墙和selinux的关闭

systemctl stop firewalld.service

systemctl disable firewalld.service

编辑selinux的配置文档/etc/sel/etc/selinux/config将SELINUX=选项设置为disable

setenforce=0

2、配置httpd server

创建itblog网站目录

mkdir /itblog

创建虚拟主机

 vim /etc/httpd/conf.d/virtualhosts.conf

<VirtualHost *:80>

ServerName itblog.cptw.com.cn

DocumentRoot "/itblog"

<Directory "/itblog">

Options None

AllowOverride None

Require all granted

</Directory>

</VirtualHost>

注释掉/etc/httpd/conf/httpd.conf中的DocumentRoot

进行http服务开启

systemctl start httpd

通过ssl -tnl查看80端口是否已经开启或者通过systemctl status httpd进行状态查看

 

3、配置mariadb,创建wordpress所需的数据库

root@itblog wordpress]# mysql

Welcome to the MariaDB monitor.  Commands end with ; or \g.

Your MariaDB connection id is 2

Server version: 5.5.50-MariaDB MariaDB Server

Copyright (c) 2000, 2016, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> GRANT ALL ON wpdb.* TO wpuser@'10.%.%.%' IDENTIFIED BY 'wppass';

Query OK, 0 rows affected (0.00 sec)

MariaDB [(none)]> create database wpdb

    -> ;

Query OK, 1 row affected (0.00 sec)

修改mariadb配置文档

vim /etc/my.cf

[mysqld]

skip_name_resolve = ON

开启数据库systemctl start mariadb.service

4、解压wordpress至网站目录

~]#unzip -c wordpress-4.5.3-zh_CN.zip  

~]# cp -rf wordpress /itblog

修改wordpress配置文档

~#] mv wp-config-sample.php wp-config.php

~#]vim wp-config.php

/** WordPress数据库的名称 */

[root@itblog wordpress]# vim wp-config.php

define('DB_NAME', 'wpdb');

/** MySQL数据库用户名 */

define('DB_USER', 'wpuser');

/** MySQL数据库密码 */

define('DB_PASSWORD', '######');

/** MySQL主机 */

define('DB_HOST', '10.55.10.79');

/** 创建数据表时默认的文字编码 */

define('DB_CHARSET', 'utf8');

此时网站即可正常访问并进行初始化设置即可

6、 插件安装

wordpress自带的文档编辑插件很土

安装Kindeditor For WordPress插件即可

安装插件问题

要执行请求的操作,WordPress需要访问您网页服务器的权限。 请输入您的FTP登录凭据

http://www.itbulu.com/wordpress-ftp.html

编辑wp-config-php的配置档,末行添加

define("FS_METHOD", "direct");

define("FS_CHMOD_DIR", 0777);

define("FS_CHMOD_FILE", 0777);

 

原创文章,作者:N23-苏州-void,如若转载,请注明出处:http://www.178linux.com/57393

(0)
N23-苏州-voidN23-苏州-void
上一篇 2016-11-03 23:10
下一篇 2016-11-04 11:07

相关推荐

  • 第四周-grep正则表达式简单应用

    复制/etc/skel目录为/home/tuser1,要求/home/tuser1及其内部文件的属组和其它用户均没有任何访问权限。 cp -r /etc/skel /home/tuser1 && chmod 700 -R /home/tuser1 编辑/etc/g…

    Linux干货 2016-08-02
  • 马哥教育21期网络班—第15周课程+练习

    2、删除/boot/grub/grub.conf文件中所有行的行首的空白字符; sed 's@^[[:space:]]\+@@' /boot/grub/grub.conf 3、删除/etc/fstab文件中所有以#开头,后跟至少一个空白字符的行的行首的#和空白字符; sed 's@^#[[:spac…

    Linux干货 2016-11-14
  • tcpdump输出详解

    在这里不得不再吐槽下国内整个IT粗糙浮躁,度娘下来的中文文档几尽抄袭~google下来的文档英文文档质量远高于国内中文文档.用ie或没有安装插件的浏览器访问,不然可能会有其它访问请求数据干扰分析 IP数据包结构 TCP数据包结构 // tcpdump需root权限 # tcpdump -x -i eth1 i…

    Linux干货 2015-04-15
  • N22网络班第一周作业

    1、 描述计算机的组成及其功能。 运算器、控制器、存储器、输入设备、输出设备 运算器、控制器 :cpu 运算和逻辑计算 存储器:缓存和保存数据 输入设备、输出设备:用户和计算机交互设备和界面 2、 按系列罗列Linux的发行版,并描述不同发行版之间的联系与区别。 Slackware系列: suse   opensuse debian系列: ubun…

    Linux干货 2016-08-15
  • N24期第四周作业

    1、复制/etc/skel目录为/home/tuser1,要求/home/tuser1及其内部文件的属组和其它用户均没有任何访问权限。 2、编辑/etc/group文件,添加组hadoop。 vim /etc/group,增加此行 3、手动编辑/etc/passwd文件新增一行,添加用户hadoop,其基本组ID为hadoop组的id号;其家目录为/home…

    Linux干货 2016-11-22
  • mysqldump的备份与恢复

    MySQL(05) 备份策略:     完全+差异+binlog(时间点还原)     完全+增量+binlog     备份,多久一次?         数据…

    Linux干货 2016-11-20