Install wordpress in LAMP Ubuntu20.04, Apache, mariadb, php8.0

Moving to this new server, everything has to be installed from scratch
Since we have to install a new version, we installed 20.04 for ubuntu.
As always, security is the most important thing, so we installed CSF and fail2ban first.
Then we installed apache, php8, and mariadb with apt-get.
The next step was to upload wordpress to the installation.
I didn’t expect to see “Your PHP installation appears to be missing the MySQL extension which is required by WordPress.” and not allowed me to install. I was dumbfounded.
Is it because the PHP version too new? I found out later that I had not installed the php extension.
I added it as below command and it was fine.

sudo apt install php8.0-snmp php-memcached php8.0-mysql

Oaky, I’m going to go ahead and install the mail server later… It’s tiring

 

移到這個新的server, 一切要從頭裝起
既然要裝就裝新版本, 所以ubuntu就裝20.04.
和往常一樣保全最重要, 所以先裝了CSF和fail2ban.
接著用apt-get 裝apache, php8, 和mariadb.
下一步就把wordpress 傳送上去安裝.
沒想到竟然出現 “Your PHP installation appears to be missing the MySQL extension which is required by WordPress.” 不給裝. 當場傻了. 難道是PHP版本太新的關係? 後來才發現少裝了 php extension.
用下面這行加了就好了.

sudo apt install php8.0-snmp php-memcached php8.0-mysql

好了, 我要繼續裝了, 等下還要裝郵件伺服器…真累人

Leave a Reply