Home > OS >  Based on build wordpress lamp
Based on build wordpress lamp

Time:12-04

/root @ localhost ~ # systemctl restart network
/root @ localhost ~ # ping baidu.com
/root @ localhost ~ # systemctl stop firewalld. Service
/root @ localhost ~ # setenforce 0
Check the source of yum
/root @ localhost ~ # yum repolist
Build a LAMP environment, use yum install
/root @ localhost ~ # yum - y install HTTPD PHP PHP - mysql mariadb mariadb server
-Add the PHP page test file
[root @ localhost ~] # CD/var/WWW/HTML/
[root @ localhost HTML] # vim index. The PHP
<? PHP
A phpinfo ()
?>

Start apche, through process and port to see success
[root @ localhost HTML] # systemctl restart HTTPD
[root @ localhost HTML] # ps - ef | grep HTTPD
[root @ localhost HTML] # ss - LNTP | grep HTTPD
Access PHP test page
[root @ localhost HTML] # firefox 192.168.12.5

Install wordpress
[root @ localhost HTML] # cp '/TMP/VMwareDnD/wordpress/8030946 e - 4.8.1 - zh_CN. Tar. Gz'../
[root @ localhost HTML] # tar ZXVF wordpress - 4.8.1 - zh_CN. Tar. Gz
Go to visit
[root @ localhost HTML] # firefox 192.168.12.5/wordpress

To the database authorization
/root @ localhost ~ # yum install mariadb server
-[root @ localhost HTML] # systemctl start mariadb
[root @ localhost HTML] # mysql
Create a database of wordpress
MariaDB [(none)] & gt; The create database charset wordpress utf8;
MariaDB [(none)] & gt; Grant all on wordpress. * to 'aaa' @ 'localhost' identified by '123'.
MariaDB [(none)] & gt; Flush privileges;
MariaDB [(none)] & gt; The quit
To visit again, click on "start now!"
[root @ localhost HTML] # firefox 192.168.12.5/wordpress
User name + password to lose his newly created database

If an error, went out, change a subordinate main belong to group can
[root @ localhost HTML] # systemctl start HTTPD
[root @ localhost HTML] # chown -r apache: apache wordpress
Visit the page again
[root @ localhost HTML] # firefox 192.168.12.5/wordpress





  • Related