How to install Wordpress CMS 4.9.6 on Ubuntu 18.04
To install Wordpress CMS 4.9.6 on Ubuntu 18.04
Wordpress is the most powerful and popular content management system (CMS) application. WordPress is a Content Management System, that allows you to create and publish your content on the web. Although it can be used for web publishing and manage content on an intranet or on a single computer.
Prerequisites
Install LAMP(Apache, MariaDB, php7)
In MariaDB (create database and user and give privileges to that user )
Php installation with required following modules
add-apt-repository ppa:ondrej/php
apt-get update
apt-get install php7.0 php7.0-mysql php7.0-curl php7.0-json php7.0-cgi libapache2-mod-php7.0 php7.0-mcrypt php7.0-xmlrpc php7.0-gd php7.0-mbstring php7.0 php7.0-common php7.0-xmlrpc php7.0-soap php7.0-xml php7.0-intl
php7.0-cli php7.0-ldap php7.0-zip php7.0-readline php7.0-imap php7.0-tidy php7.0-recode php7.0-sq php7.0-intl
Installation
Download a Wordpress CMS package using the following URL
root@linuxhelp1:/home/user1/Downloads# wget https://wordpress.org/latest.zip
--2018-05-24 21:23:12-- https://wordpress.org/latest.zip
Resolving wordpress.org (wordpress.org)... 198.143.164.252
Connecting to wordpress.org (wordpress.org)|198.143.164.252|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 9502138 (9.1M) [application/zip]
Saving to: ‘ latest.zip’
latest.zip 100%[==============================> ] 9.06M 668KB/s in 13s
2018-05-24 21:23:26 (721 KB/s) - ‘ latest.zip’ saved [9502138/9502138]
The downloaded package is a zip file, so unzip the file using the following command
root@linuxhelp1:/home/user1/Downloads# unzip latest.zip
Archive: latest.zip
creating: wordpress/
inflating: wordpress/xmlrpc.php
inflating: wordpress/wp-blog-header.php
inflating: wordpress/readme.html
.
.
inflating: wordpress/wp-admin/admin-header.php
inflating: wordpress/wp-admin/post-new.php
inflating: wordpress/wp-admin/themes.php
inflating: wordpress/wp-admin/options-reading.php
inflating: wordpress/wp-trackback.php
inflating: wordpress/wp-comments-post.php
Move the extracted file into the following path
root@linuxhelp1:/home/user1/Downloads# mv wordpress /var/www/
Switch to the following directory
root@linuxhelp1:/home/user1/Downloads# cd /var/www/
Change the ownership and permission of the file
root@linuxhelp1:/var/www# chown -R www-data.www-data wordpress
root@linuxhelp1:/var/www# chmod -R 775 wordpress
Create a new virtual host configuration for accessing the Wordpress CMS application
root@linuxhelp1:/var/www# vim /etc/apache2/sites-available/wordpress.conf
< VirtualHost *:80>
ServerName www.linuxhelp1.com
DocumentRoot /var/www/wordpress
< Directory /var/www/wordpress>
AllowOverride All
allow from all
< /Directory>
< /VirtualHost>
Enable the site access
root@linuxhelp1:/var/www# a2ensite wordpress.conf
Enabling site wordpress.
To activate the new configuration, you need to run:
systemctl reload apache2
Disable the default access
root@linuxhelp1:/var/www# a2dissite 000-default.conf
Site 000-default disabled.
To activate the new configuration, you need to run:
systemctl reload apache2
Enable the rewrite module
root@www:/var/www# a2enmod rewrite
Enabling module rewrite.
To activate the new configuration, you need to run:
systemctl restart apache2
Restart the apache2 service
root@linuxhelp1:/var/www# systemctl restart apache2
Now you can proceed the further installation and configuration from the browser by navigating to the following URL: http://< ipaddress or domain name
Choose the language for using Wordpress
Configure the database setup
Setup the database details
Run the installation
Configure the site information
After the successful installation, you will see the following page
Log in using the admin user credential
After the successful login, you will see the Dashboard of Wordpress
You can customize your site from the following available options on the left panel
With this, the method to install Wordpress CMS 4.9.6 on Ubuntu 18.04 comes to an end.