Centos 搭建wordpress個人博客


 

1、裝apache、mariadb

yum install  httpd  mariadb-server  php php-mysql -y
systemctl start httpd
systemctl enable httpd
systemctl start mariadb
systemctl enable mariadb

2、mariadb配置

密碼初始化
mysql_secure_installation


創建一個數據庫wordpress
mysql -u root -p
MariaDB [(none)]> create database wordpress character set utf8 collate utf8_bin;
MariaDB [(none)]> grant all on wordpress.* to  wordpress@'localhost' identified by 'wordpress';
MariaDB [(none)]> grant all on wordpress.* to  wordpress@'%' identified by 'wordpress';
MariaDB [(none)]> exit

 3、安裝wordpress

官網:https://cn.wordpress.org/

下載
wget https://cn.wordpress.org/wordpress-4.8.1-zh_CN.tar.gz
解壓
tar -zxf wordpress-4.8.1-zh_CN.tar.gz
移動到html目錄下
mv wordpress /var/www/html/
重啟httpd服務
systemctl restart httpd

4、頁面訪問 ip/wordpress web端安裝

按照提示在 wordpress目錄下創建wp-config.php並配置
cd /var/www/html/wordpress/
vi wp-config.php

最后面填入一些賬號密碼信息即可完成!

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM