wordpress安装

  • 1.部署apache服务
  • 2.部署MariaDB服务
  • 3.部署PHP服务
  • 4.安装wordpress

翻找网上的教程基本都是之前的
很多都不匹配,比如PHP版本过低不支持新版wordpress
这里做一个更新,每一步都有详细说明

1.部署apache服务

#安装http服务
[root@xiudaochengxian ~]# yum -y install httpd
#启动http服务,并加入开机启动项
[root@xiudaochengxian ~]# systemcel start httpd
[root@xiudaochengxian ~]# systemcel enable httpd
#查看http服务状态
[root@xiudaochengxian ~]# systemcel status httpd
#打开浏览器输入本机地址
出现apache默认界面即为安装成功
#关闭防火墙
[root@xiudaochengxian ~]# systemcel stop firewalld

2.部署MariaDB服务

也可用MySQL,但是MariaDB安装使用都方便

MariaDB详细安装步骤点此

#安装mariadb
[root@xiudaochengxian ~]# yum -y install mariadb mariadb-server
#初始化数据库
[root@xiudaochengxian ~]# mysql_secure_installation
#启动数据库服务,并加入开机启动项
[root@xiudaochengxian ~]# systemcel start mariadb
[root@xiudaochengxian ~]# systemcel enable mariadb
#查看mariadb服务启动状态
[root@xiudaochengxian ~]# systemcel status mariadb

3.部署PHP服务

分界线下面是升级操作,非必须

#安装php和php-mysql(如果未安装此包,打开wordpress可能会报错)
[root@xiudaochengxian ~]# yum -y install php php-mysql
#安装php补丁包,也是一个php控制台
[root@xiudaochengxian ~]# yum -y install php-fpm
#启动php-fpm服务
[root@xiudaochengxian ~]# systemctl start php-fpm
#查看php-fpm服务启动状态
[root@xiudaochengxian ~]# systemctl status php-fpm
#查看php版本,如果版本过低,进行下面升级操作,反之不用
[root@xiudaochengxian ~]# php -v
---------------------------------------------------------------------------------
#删除之前的php
[root@xiudaochengxian ~]# yum remove php-common
#安装php软件yum源
[root@xiudaochengxian ~]# rpm -Uvh https://mirror.webtatic.com/yum/el7/epel-release.rpm
[root@xiudaochengxian ~]# rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
#安装php 5.6版本(php56w-devel这个不是必需的)
[root@xiudaochengxian ~]# yum -y install php56w php56w-opcache php56w-xml php56w-mcrypt php56w-gd php56w-devel php56w-mysql php56w-intl php56w-mbstring php56w-fpm
#可以查看下缺失了那些依赖包
[root@xiudaochengxian ~]# yum search php56w
#重启http服务
[root@xiudaochengxian ~]# systemctl restart httpd
#查看php版本
[root@xiudaochengxian ~]# php -v

4.安装wordpress

#从国内的一些网站下载wp源码包,速度较快(也可以从官网下载)
[root@xiudaochengxian ~]# wget https://www.linuxprobe.com/Software/wordpress.tar.gz
#解压wordpress源码包
[root@xiudaochengxian ~]# tar xzvf wordpress.tar.gz
#将WordPress解压后的网站文件复制进去
[root@xiudaochengxian ~]# mv wordpress/* /var/www/html/
#切换到http服务网站默认路径
[root@xiudaochengxian ~]# cd /var/www/html/
#查看是否复制成功
[root@xiudaochengxian html]# ll
total 208
-rw-r--r--  1 1006 1006   405 Feb  6  2020 index.php
-rw-r--r--  1 1006 1006 19915 Jan  1  2021 license.txt
-rw-r--r--  1 1006 1006  7345 Dec 30  2020 readme.html
-rw-r--r--  1 1006 1006  7165 Jan 21  2021 wp-activate.php
drwxr-xr-x  9 1006 1006  4096 May  4  2021 wp-admin
-rw-r--r--  1 1006 1006   351 Feb  6  2020 wp-blog-header.php
-rw-r--r--  1 1006 1006  2328 Feb 17  2021 wp-comments-post.php
-rw-r--r--  1 1006 1006  2913 Feb  6  2020 wp-config-sample.php
drwxr-xr-x  5 1006 1006  4096 May  4  2021 wp-content
-rw-r--r--  1 1006 1006  3939 Jul 31  2020 wp-cron.php
drwxr-xr-x 25 1006 1006 12288 May  4  2021 wp-includes
-rw-r--r--  1 1006 1006  2496 Feb  6  2020 wp-links-opml.php
-rw-r--r--  1 1006 1006  3313 Jan 11  2021 wp-load.php
-rw-r--r--  1 1006 1006 44994 Apr  5  2021 wp-login.php
-rw-r--r--  1 1006 1006  8509 Apr 14  2020 wp-mail.php
-rw-r--r--  1 1006 1006 21125 Feb  2  2021 wp-settings.php
-rw-r--r--  1 1006 1006 31328 Jan 28  2021 wp-signup.php
-rw-r--r--  1 1006 1006  4747 Oct  9  2020 wp-trackback.php
-rw-r--r--  1 1006 1006  3236 Jun  9  2020 xmlrpc.php
#复制wordpress基本配置文件
[root@xiudaochengxian html]# cp wp-config-sample.php wp-config.php
#进入mariadb,创建用于网站的数据库
[root@xiudaochengxian html]# mysql -u root -p
Enter password:
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 13
Server version: 5.5.68-MariaDB MariaDB ServerCopyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.MariaDB [(none)]> create database wordpress;
Query OK, 1 row affected (0.00 sec)MariaDB [(none)]> exit
Bye#编辑wordpress基本配置文件
[root@xiudaochengxian html]# vim wp-config.php
define( 'DB_NAME', '创建的数据库名称,这里是wordpress' );/** MySQL database username */
define( 'DB_USER', '用户,这里是root' );/** MySQL database password */
define( 'DB_PASSWORD', '自己设置的密码' );#重启http服务
[root@xiudaochengxian ~]# systemcel restart httpd
#浏览器输入本机地址即可打开wordpress默认界面

LAMP环境搭建wordpress相关推荐

  1. 使用LAMP环境搭建wordpress论坛

    1.      搭建LAMP架构 (1)      rpm搭建LAMP环境 [root@HK36 ~]# yum install httpd mysql-server mysql php php-my ...

  2. Ubuntu 20.04 上搭建 LEMP/LAMP 环境运行 WordPress

    Ubuntu 20.04 上搭建 LEMP 环境运行 WordPress Wordpress 是最流行的内容管理系统之一,也是常用的 CMS(内容管理系统)程序之一.Wordpress 可以在 VPS ...

  3. LAMP环境搭建之rpm软件包

    Linux+Apache+Mysql+Perl/PHP/Python一组常用来搭建动态网站或者服务器的开源软件,本身都是各自独立的程序,但是因为常被放在一起使用,拥有了越来越高的兼容度,共同组成了一个 ...

  4. 基于ECS部署LAMP环境搭建Drupal网站,云计算技术与应用报告

    实验环境: 建站环境:Windows操作系统,基于ECS部署LAMP环境,阿里云资源, Web服务器:Apache,关联的数据库:MySQ PHP:Drupal 8 要求的PHP版本為7.0.33的版 ...

  5. 阿里云ubuntu14.04下lamp环境搭建の备忘

    以下内容大部分来自于网络上的收集,百度搜lamp能搜到很多文字教程.百度lamp搭建 推荐几个视频教程: 在Ubuntu Server下搭建LAMP环境 PHP环境LAMP/LNMP安装与配置 我收藏 ...

  6. LAMP攻略: LAMP环境搭建,Linux下Apache,MySQL,PHP安装与配置

    之前写过一个red hat 9下的LAMP环境的配置,不过由于版本比较旧,很多不适用了. 所以决定写一个新的LAMP环境搭建与配置教程.本配置是在 CentOS-5.3 下 httpd-2.2.11. ...

  7. LAMP环境搭建教程

    这里介绍一下LAMP环境的搭建,即Linux.Apache.MySQL.PHP环境. 一.首先安装操作系统 操作系统:centos6.3       (Linux平台的系统均可尝试) IP地址: 网关 ...

  8. LAMP环境搭建之编译安装指南(php-5.3.27.tar.gz)

    测试环境:CentOS release 6.5 (Final) 软件安装:httpd-2.2.27.tar.gz   mysql-5.1.72.tar.gz   php-5.3.27.tar.gz 1 ...

  9. win2012 r2 iis php,Win2012 R2 IIS8.5+PHP(FastCGI)+MySQL运行环境搭建wordpress博客教程

    运行环境搭建教程 一.环境说明: 操作系统:Windows Server2012 R2 PHP版本:php 5.5.8 MySQL版本:MySQL5.6.15 二.相关软件下载: 1.PHP下载地址: ...

最新文章

  1. 【Qt】通过QtCreator源码学习Qt(十):多国语言支持
  2. 其实不的免费图标网站
  3. 1.18.2.Table APISQL(概念与通用API、两种计划器(Planner)的主要区别、创建 TableEnvironment、临时表、永久表、创建表、虚拟表、Connector 等)
  4. c语言文件加密异或操作,用异或算法实现文件的简单加密
  5. 对‘TIFFReadDirectory@LIBTIFF_4.0’未定义的引用
  6. ciclop读音,购机必备,15种 3D扫描 设备 优缺点汇总
  7. 微信新的用户信息接口wx.getUserProfile,返回信息解密失败
  8. rust加载不进去服务器eac_基于腾讯云的 Rust 和 WebAssembly 函数即服务
  9. 沪江日语电台首度在线直播后续花絮(附直播片段)
  10. python将字符串写入txt文件_python将字符串以utf-8格式保存在txt文件中的方法
  11. 现外供电电压都达240V,音响系统要不要加稳压器?
  12. oracle 已知表名查询所属的schema_sql注入联合查询总结
  13. Cocos2dx入门
  14. 告诉你一个真实的北京
  15. 上面两点下面一个三角形_图形学底层探秘 - 更现代的三角形光栅化与插值算法的实现与优化...
  16. Mac修改iPhone备份到移动硬盘或其他位置,避免备份空间不足
  17. 【PLM—1】——2019-NAACL-Bert
  18. Vector诊断系统开发流程及其工具链
  19. Qt小程序之自绘震动铃铛提示控件
  20. 计算机作为信息处理工具 应用于科学研究,计算机2013分春章节试题及答案.doc

热门文章

  1. mysql如何存储bitmap_[MySQL] mysql中bitmap的简单运用
  2. java int的最大值_int 最大值
  3. Jsp如何连接MySQL
  4. 贝叶斯算法+贝叶斯实践
  5. 拼多多API接口详情,item_get-根据ID取商品详情
  6. 图解c/c++多级指针与“多维”数组,拿捏住了
  7. 浦东朋友居转户时间线
  8. 如何打开屏幕坏的手机_手机屏幕碎了,别急着换屏,教你一招如何修复!
  9. HLA-A单克隆抗体参考说明书
  10. 《炬丰科技-半导体工艺》种植体表面酸蚀