Now I want to share how to install WordPress on ubuntu 20.04 server. WordPress is an most popular opensource CMS. You can install on your vps or local server using my tutorial.
My server info :
Server IP : 10.66.11.15
Disk : 25 GB
RAM : 1GB
vCPU : 2
Service : WordPress
Web : Apache
Database : Mariadb
Php : 7.4
root@WordPress:~# lsb_release -a root@WordPress:~# ip r
root@WordPress:~# apt-get update && apt-get upgrade -y root@WordPress:~# apt-get install apache2 apache2-utils -y root@WordPress:~# systemctl enable apache2 root@WordPress:~# systemctl start apache2 root@WordPress:~# apt install mariadb-server -y root@WordPress:~# systemctl enable mariadb root@WordPress:~# systemctl start mariadb root@WordPress:~# mysql_secure_installation
Press y| Y << Type Y press enter
Do you want to continue press y|Y << Type Y press enter
Remove anonymous user press y|Y << Remove anonymous user type Y press enter
Disallow root login remoetly y|Y << Disallow root user login type Y press enter
Remove test database and access to it y|Y << Remove test database type Y press enter
Reload privilege tables now? y|Y << Reload all tables type Y press enter
root@WordPress:~# apt-get install php7.4 php7.4-mysql libapache2-mod-php7.4 php7.4-cli php7.4-cgi php7.4-gd -y root@WordPress:~# vi /var/www/html/tech.php
Insert below code into tech.php file.
//PHP code goes here
Browse your server ip address with file name tech.php
http://10.66.11.15/tech.php
root@WordPress:~# wget -c http://wordpress.org/latest.tar.gz root@WordPress:~# tar -xzvf latest.tar.gz root@WordPress:~# rsync -av wordpress/* /var/www/html/ root@WordPress:~# chmod -R 755 /var/www/html/ root@WordPress:~# chown -R www-data:www-data /var/www/html/ root@WordPress:~# rm -rf /var/www/html/index.html
root@WordPress:~# mysql -u root -p
If you not setup mysql root password from step #2 last command. So it is default password is blank.
MariaDB [(none)]> create database wp_db; MariaDB [(none)]> grant all privileges on wp_db.* to 'wp_db_user'@'localhost' identified by 'wp_db_passw0rd'; MariaDB [(none)]> flush privileges; MariaDB [(none)]> q
root@WordPress:~# mv /var/www/html/wp-config-sample.php /var/www/html/wp-config.php root@WordPress:~# vi /var/www/html/wp-config.php
Now insert below details already created from Step #4.
define('DB_NAME', 'wp_db');
define('DB_USER', 'wp_db_user');
define('DB_PASSWORD', 'wp_db_passw0rd');
define('DB_HOST', 'localhost');
define('DB_CHARSET', 'utf8');
define('DB_COLLATE', '');
Restart apache and mariadb server and check default vHost file is ok.
root@WordPress:~# systemctl restart apache2.service root@WordPress:~# systemctl restart mariadb.service root@WordPress:~# vi /etc/apache2/sites-available/000-default.conf
Like example below
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ServerName server_domain_name_or_IP
AllowOverride All
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
root@WordPress:~# a2enmod rewrite root@WordPress:~# systemctl restart apache2 root@WordPress:~# touch /var/www/html/.htaccess root@WordPress:~# chown :www-data /var/www/html/.htaccess root@WordPress:~# chmod 664 /var/www/html/.htaccess root@WordPress:~# service apache2 restart
Now browse your server ip address and complete installation process.
http://10.66.11.15/
Then click Continue and type site title, Username, Password and Your Email. Now click Install WordPress.
If all is ok so you see Success!
WordPress has been installed. Thank you and enjoy!
For more details see my YouTube video.
The post How To Install WordPress On Ubuntu 20.04 appeared first on TechnologyRSS.
Here’s the guide to deploy Elastic Stack on Ubuntu VPS, with secure access, HTTPS proxying,…
This guide walks through deploying Nagios Core on an Ubuntu VPS, from system prep to…
After a decade under Pablo Cantero's stewardship, Shoryuken has a new maintainer - me. I'm…
MAAS 3.7 has been officially released and it includes a bunch of cool new features.…
Update: This article originally concluded that Eisel-Lemire wasn't worth it for Ruby. I was wrong.…
Recently, the team at MinIO moved the open source project into maintenance mode and will…