CentOS搭建lamp環境和wordpress

2022-02-04 00:42:55 字數 1166 閱讀 1519

參考

系統環境:

vim /var/www/html/test.php 在檔案中錄入:<?phpecho"test page"; phpinfo()?>瀏覽器視窗訪問:http://localhost/test.php,出現php資訊則說明成功.

use mysql; grant all privileges on *.* to root@'%' identified by 'mypass'; select host,user,password from user; 重新整理許可權:flush privileges;  

wgettar -zxvfwordpress-4.9-zh_cn.tar.gz mv wordpress /var/www/html ls /var/www/html/wordpress  

create database wordpress charset utf8mb4;  

瀏覽器中訪問: http://localhost/wordpress/wp-admin/install.php 或者 http://

localhost

/wordpress/wp-admin/setup-config.php 或者 http://

localhost

/wordpress/ 會自動進入wordpress安裝介面,填寫資料庫資訊.點選提交.wordpress會自動進行下一步的安裝或者訪問:  

環境引數: web根目錄:/var/www/html

apache/2.4.6 (centos) php/5.4.16

mysql:5.5.56-mariadb

CentOS搭建LAMP環境

1.搭建 mysql 資料庫 安裝 mysql 使用yum安裝 mysql yum install mysql server y安裝完成後,啟動 mysql 服務 service mysqld restart設定 mysql 賬戶 root 密碼 usr bin mysqladmin u root ...

Centos 搭建LAMP環境

1.安裝apache systemctl start httpd.service 啟動apache systemctl stop httpd.service 停止apache systemctl restart httpd.service 重啟apache systemctl enable http...

CentOS搭建LAMP環境

更新包 yum update yum upgrade 安裝apache httpd 測試安裝是否成功,訪問伺服器ip,若有apache頁面,即為安裝成功 wget i c yum y install mysql57 community release el7 10.noarch.rpm 安裝mysq...