How To Install Cacti Monitoring V1.2.3 on Ubuntu 18.04 LTS

Cacti Monitoring

Cacti is an open-source, web-based network monitoring and graphing tool designed as a front-end application for the open-source, industry-standard data logging tool RRDtool. It is used by IT businesses and stores all of the necessary information about bandwidth, hard disk usage, CPU usage, load average, RAM statistics etc in a MySQL database. Cacti creates graphs and populates them with data. It offers SNMP support, 3rd party templates and plugins and has built in user authentications and user permission features.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Cacti Monitoring on a Ubuntu 18.04 (Bionic Beaver) server.

Install Cacti Monitoring on Ubuntu 18.04 LTS

Step 1. First make sure that all your system packages are up-to-date Install Cacti Monitoring on Ubuntu 18

sudo apt-get update
sudo apt-get upgrade

Step 2. Install LAMP (Linux, Apache, MariaDB and PHP) server.

A Ubuntu 18.04 LAMP server is required. If you do not have LAMP installed, you can follow our guide here. Also install all required PHP modules:

apt-get install php7.1-cli php7.1-gd php7.1-opcache php7.1-mysql php7.1-json php7.1-mcrypt php7.1-xml php7.1-curl

Step 3. Configuring MariaDB for Cacti.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. you should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB:

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MariaDB console and create a database for the Cacti. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MariaDB root password and hit Enter. Once you are logged in to your database server you need to create a database for Cacti installation:

Ccreate database cacti;
GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'cactipassword';
flush privileges;
exit

The newly created database user (cactiuser) should have access to the mysql.time_zone_name Table. To do that, import the mysql_test_data_timezone.sql to mysql database:

mysql -u root -p mysql < /usr/share/mysql/mysql_test_data_timezone.sql

Then, log in to Mariadb:

mysql -u root -p

Grant the permission to cactiuser:

GRANT SELECT ON mysql.time_zone_name TO cactiuser@localhost;
flush privileges;
exit

Step 4. Installing the Cacti packages.

Install SNMP and SNMP and RRDtools:

sudo apt-get install snmp snmpd snmp-mibs-downloader rrdtool

Now use the following command to install Cacti:

apt-get install cacti cacti-spine

During the installation process you will be prompted to configure Cacti with few options to select from available options. First of all Choose the web server that you wish to use for configure with Cacti like we are using Apache and then press ‘OK’ key to continue:

cacti-installation-ubunut-1

Now it will ask you for a webserver that you will use it, we choose Apache2 since that’s what we installed in the dependencies.
cacti-installation-ubunut-2

Next it will ask to configure the Cacti database, select Yes.
cacti-installation-ubunut-3
Now it will ask for your root password of MySQL/MariaDB database.
cacti-installation-ubunut-4

Once the installation process is complete, you will have to restart all services to reflect the changes made:

systemctl restart apache2.service
systemctl restart mysql.service
systemctl restart snmpd.service

Step 5. Accessing cacti.

Cacti will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/cacti or http://server-ip/cacti and complete the required the steps to finish the installation. You will get the “Cacti Installation Guide” on screen. Click on ‘Next’ button.

In next screen, you will get drop down button. Because this fresh installation select ‘New Install’ and click ‘Next’ button.
Cacti_installing-2
Cacti will now check for the packages it needs to run properly. Make sure all the checks appear with an “OK” status, and then click Finish.
Cacti_installing-3
The next page is the login page. The first time you log into Cacti, use admin as username and password.
Cacti-installing-4

Congratulation’s! You have successfully installed Cacti. Thanks for using this tutorial for installing Cacti Monitoring on Ubuntu 18.04 LTS (Bionic Beaver) system. For additional help or useful information, we recommend you to check the official Cacti Monitoring web site.

How To Install Habari CMS V0.9.2 on Ubuntu 18.04 LTS

Install Habari CMS on Ubuntu 18

Habari is a free and open source blog engine written in PHP and currently supports MySQL, SQLite and PostgreSQL for the database backend and application framework with a modular, object-oriented core.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Habari CMS on a Ubuntu 18.04 LTS (Bionic Beaver) server.

Install Habari CMS on Ubuntu 18.04 LTS

 

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Install LAMP (Linux, Apache, MariaDB and PHP) server.

A Ubuntu 18.04 LAMP server is required. If you do not have LAMP installed, you can follow our guide here. Also install all required PHP modules:

apt-get install php7.1-cli php7.1-gd php7.1-opcache php7.1-mysql php7.1-json php7.1-mcrypt php7.1-xml php7.1-curl

Step 3. Installing Habari on Ubuntu 18.04 LTS.

First thing to do is to go to Habari’s download page and download the latest stable version of Habari, At the moment of writing this article it is version 0.9.2:

wget http://habariproject.org/dist/habari-0.9.2.zip
sudo mkdir -p /var/www/html/habari
sudo unzip habari-0.9.2.zip -d /var/www/html/habari

We will need to change some folders permissions:

sudo chown -R www-data:www-data /var/www/html/habari/
sudo chmod -R 755 /var/www/html/habari/

Step 4. Configuring MariaDB for Habari.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. you should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB:

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MariaDB console and create a database for the Habari. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MariaDB root password and hit Enter. Once you are logged in to your database server you need to create a database for Habari installation:

create database habari;
grant all privileges on habari.* to habariuser@localhost identified by 'your_password';
flush privileges;
exit

Step 5. Configuring Apache web server for Habari.

Create a new virtual host directive in Apache. For example, create a new Apache configuration file named ‘habari.conf’ on your virtual server:

touch /etc/apache2/sites-available/habari.conf
ln -s /etc/apache2/sites-available/habari.conf /etc/apache2/sites-enabled/habari.conf
nano /etc/apache2/sites-available/habari.conf

Add the following lines:

<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /var/www/html/habari
ServerName your-domain.com
ServerAlias www.your-domain.com
<Directory /var/www/html/habari/>
Options FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/your-domain.com-error_log
CustomLog /var/log/apache2/your-domain.com-access_log common
</VirtualHost>

Now, we can restart Apache web server so that the changes take place:

a2ensite habari.conf
a2enmod rewrite
systemctl restart apache2.service

Step 6. Accessing Habari.

Habari will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/ or http://server-ip and complete the required the steps to finish the installation. If you are using a firewall, please open port 80 to enable access to the control panel.

Congratulation’s! You have successfully installed Habari. Thanks for using this tutorial for installing Habari Content Management System on your Ubuntu 18.04 LTS (Bionic Beaver) system. For additional help or useful information, we recommend you to check the official Habari web site.

How To Install PrestaShop on Ubuntu 18.04 LTS

Install PrestaShop on Ubuntu 18

PrestaShop is an open-source e-commerce solution which allows you to maintain your own online shop. It PrestaShop is 100% free. This software is published under the Open Software License (OSL). It is written in PHP programming language with support for the MySQL database management system. More than 250,000 ecommerce sites run on PrestaShop. It supports many different payment gateway systems like PayPal, Google Checkout etc.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation PrestaShop open-source shopping cart on a Ubuntu 18.04 LTS (Bionic Beaver) server.

Install PrestaShop on Ubuntu 18.04 LTS

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Install LAMP (Linux, Apache, MariaDB and PHP) server.

A Ubuntu 18.04 LAMP server is required. If you do not have LAMP installed, you can follow our guide here. Also install all required PHP modules:

apt-get install php7.1-cli php7.1-gd php7.1-opcache php7.1-mysql php7.1-json php7.1-mcrypt php7.1-xml php7.1-curl

Step 3. Installing PrestaShop on Ubuntu 18.04 LTS.

First thing to do is to go to PrestaShop’s download page and download the latest stable version of PrestaShop, At the moment of writing this article it is version 1.7.3.3:

wget https://download.prestashop.com/download/releases/prestashop_1.7.3.3.zip

Unpack the PrestaShop archive to the document root directory on your server:

unzip prestashop_1.7.3.3.zip -d /var/www/html

We will need to change some folders permissions:

chown -R www-data.www-data /var/www/html/prestashop

Step 4. Configuring MariaDB for PrestaShop.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. you should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB:

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MariaDB console and create a database for the PrestaShop. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MariaDB root password and hit Enter. Once you are logged in to your database server you need to create a database for PrestaShop installation:

CREATE DATABASE prestashop;
CREATE USER 'prestashopuser'@'localhost' IDENTIFIED BY 'PASSWORD';
GRANT ALL PRIVILEGES ON `prestashop`.* TO 'prestashopuser'@'localhost';
FLUSH PRIVILEGES;

Step 5. Configuring Apache web server for PrestaShop.

Create a new virtual host directive in Apache. For example, create a new Apache configuration file named ‘prestashop.conf’ on your virtual server:

sudo a2enmod rewrite
touch /etc/apache2/sites-available/prestashop.conf
ln -s /etc/apache2/sites-available/prestashop.conf /etc/apache2/sites-enabled/prestashop.conf
nano /etc/apache2/sites-available/prestashop.conf

Add the following lines:

<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /var/www/html/prestashop/
ServerName your-domain.com
ServerAlias www.your-domain.com
<Directory /var/www/html/prestashop/>
Options FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/your-domain.com-error_log
CustomLog /var/log/apache2/your-domain.com-access_log common
</VirtualHost>

Now, we can restart Apache web server so that the changes take place:

systemctl restart apache2.service

Step 6. Accessing PrestaShop.

PrestaShop will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/ or http://server-ip/ and complete the required the steps to finish the installation. If you are using a firewall, please open port 80 to enable access to the control panel.

install-PrestaShop

Congratulation’s! You have successfully installed PrestaShop. Thanks for using this tutorial for installing PrestaShop open-source shopping cart software on your Ubuntu 18.04 LTS (Bionic Beaver) system. For additional help or useful information, we recommend you to check the official PrestaShop web site.

How To Install phpMyAdmin 4.8.5 on Ubuntu 18.04 LTS

Install phpMyAdmin on Ubuntu 18

phpMyAdmin is web-based client written in php for managing MySQL and MariaDB databases. It provides a user friendly web interface to access and manage your databases. To ease usage to a wide range of people, phpMyAdmin is being translated into 72 languages and supports both LTR and RTL languages.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation phpMyAdmin on a Ubuntu 18.04 LTS (Bionic Beaver) server.

Install phpMyAdmin on Ubuntu 18.04 LTS

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Install LAMP (Linux, Apache, MariaDB and PHP) server.

A Ubuntu 18.04 LAMP server is required. If you do not have LAMP installed, you can follow our guide here. Also install all required PHP modules:

apt-get install php7.1-cli php7.1-gd php7.1-opcache php7.1-mysql php7.1-json php7.1-mcrypt php7.1-xml php7.1-curl

Step 3. Installing phpMyAdmin on Ubuntu 18.04 LTS.

Use this command to install phpmyadmin on Ubuntu 18.04:


sudo apt install phpmyadmin

Important, this step will ask you to select the web server where the application would be installed, it is mandatory that you select with the spacebar “Apache” server or your designate, not doing this will cause the files wont’t be copied correctly and then can not find the installed application.

Step 4. Accessing phpMyAdmin.

Now open your browser and surf to http://your-ip-address/phpmyadmin and your phpmyadmin will ask you for user and password of your mysql installation such as on step 2, you can use root as user and the root mysql password, or any other mysql user/password. If you are using a firewall, please open port 80 to enable access to the control panel.

phpMyAdmin-login

Congratulation’s! You have successfully installed phpMyAdmin. Thanks for using this tutorial for installing phpMyAdmin on Ubuntu 18.04 LTS system. For additional help or useful information, we recommend you to check the official phpMyAdmin web site.

How To Install Nextcloud on Ubuntu 18.04 LTS

Install Nextcloud on Ubuntu 18

Nextcloud is open source self-hosted file sync and share application (Calendar, Contacts, Documents, Email, and more). The developers at Nextcloud are doing their best to give the users a more secure platform, fewer bugs and overall a better product.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Nextcloud on a Ubuntu 18.04 LTS (Bionic Beaver) server.

Install Nextcloud on Ubuntu 18.04 LTS

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Install LAMP (Linux, Apache, MariaDB and PHP) server.

A Ubuntu 18.04 LAMP server is required. If you do not have LAMP installed, you can follow our guide here. Also install all required PHP modules:

apt-get install php7.1-cli php7.1-gd php7.1-opcache php7.1-mysql php7.1-json php7.1-mcrypt php7.1-xml php7.1-curl

Step 3. Installing Nextcloud.

First thing to do is to go to Nextcloud’s download page and download the latest stable version of Nextcloud, At the moment of writing this article it is version 13.0.2:

wget https://download.nextcloud.com/server/releases/nextcloud-13.0.2.zip

Unpack the Nextcloud archive to the document root directory on your server:

unzip nextcloud-13.0.2.zip
mv nextcloud /var/www/html

We will need to change some folders permissions:

chown -R www-data:www-data /var/www/html/nextcloud

Step 4. Configuring MariaDB for Nextcloud.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. You should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB.

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MariaDB console and create a database for the Nextcloud. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MariaDB root password and hit Enter. Once you are logged in to your database server you need to create a database for Nextcloud installation:

MariaDB [(none)]> CREATE DATABASE nextcloud;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON nextcloud.* TO 'nextcloud'@'localhost' IDENTIFIED BY 'strong_password';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> \q

Disable MariaDB binary logging by commenting the following lines:

nano /etc/mysql/my.cnf

Add the following three lines in [mysqld] section:

log-bin        = /var/log/mysql/mariadb-bin
log-bin-index  = /var/log/mysql/mariadb-bin.index
binlog_format  = mixed

Step 5. Configuring Apache web server for Nextcloud.

Create a new virtual host directive in Apache. For example, create a new Apache configuration file named ‘nextcloud.conf’ on your virtual server:

sudo a2enmod rewrite
touch /etc/apache2/sites-available/nextcloud.conf
ln -s /etc/apache2/sites-available/nextcloud.conf /etc/apache2/sites-enabled/nextcloud.conf
nano /etc/apache2/sites-available/nextcloud.conf

Add the following lines:

<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "/var/www/html/nextcloud/"
ServerName your-domain.com
ServerAlias www.your-domain.com
<Directory "/var/www/html/nextcloud/">
Options FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/your-domain.com-error_log
CustomLog /var/log/apache2/your-domain.com-access_log common
</VirtualHost>

Now, we can restart Apache web server so that the changes take place:

systemctl restart apache2.service

Step 6. Accessing Nextcloud.

Nextcloud will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/ or http://server-ip/ and complete the required the steps to finish the installation. If you are using a firewall, please open port 80 to enable access to the control panel. What you do with Nextcloud is up to you. You can add new modules or just use it as a cloud-based file sync and share. You can install the Android app and even make use of the ownCloud desktop clients (they’ll work fine with Nextcloud).

install-nextcloud-on-Ubuntu-16.04

Congratulation’s! You have successfully installed Nextcloud. Thanks for using this tutorial for installing Nextcloud personal cloud storage on your Ubuntu 18.04 LTS (Bionic Beaver) system. For additional help or useful information, we recommend you to check the official Nextcloud web site.

How To Install PostgreSQL 11.2 on Ubuntu 18.04 LTS

Install PostgreSQL on Ubuntu 18

PostgreSQL is a free, open-source object-relational database management system (object-RDBMS), similar to MySQL, and is standards-compliant and extensible. It is commonly used as a back-end for web and mobile applications. PostgreSQL, or ‘Postgres’ as it is nicknamed, adopts the ANSI/ISO SQL standards together, with the revisions.

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation PostgreSQL on a Ubuntu 18.04 (Bionic Beaver) server.

Install PostgreSQL on Ubuntu 18.04 LTS

Step 1. First make sure that all your system packages are up-to-date

sudo apt-get update
sudo apt-get upgrade

Step 2. Installing PostgreSQL server on Ubuntu 18.04 LTS.

PostgreSQL is available in the default repositories. So enter the following command from the Terminal to install it:

apt install postgresql postgresql-contrib phppgadmin

Step 3. Access PostgreSQL command prompt.

After installing PostgreSQL database server, by default it creates a user ‘postgres’ with role ‘postgres’. It also creates a system account with same name ‘postgres’. So to connect to postgres server, login to your system as user postgres and connect database:

su - postgres
psql

Now you are logged in to PostgreSQL database server. To check login info use following command from database command prompt:

postgres-# \conninfo

To disconnect from PostgreSQL database command prompt just type below command and press enter. It will return you back to Ubuntu command prompt:

postgres-# \q

Create new user and database:

### For example, let us create a new user called “mona” with password “ramona”, and database called “monadb”. ###
sudo -u postgres createuser -D -A -P mona
sudo -u postgres createdb -O mona monadb

Step 4. Configure Apache2 for phpPgAdmin.

phpPgAdmin is a web-based administration tool for PostgreSQL. It is perfect for PostgreSQL DBAs, newbies, and hosting services. You need to configure apache for phpPgAdmin. Edit the file /etc/apache2/conf-available/phppgadmin.conf:

nano /etc/apache2/conf-available/phppgadmin.conf

Comment out the line #Require local by adding a # in front of the line and add below the line allow from all so that you can access from your browser:
phpPgAdmin-apache2-conf

Step 5. Configure phpPgAdmin.

Next, edit the file /etc/phppgadmin/config.inc.php:

nano /etc/phppgadmin/config.inc.php

Now change the following option:

$conf[‘extra_login_security'] = true;
to
$conf[‘extra_login_security'] = false;

Now, we can restart Apache and phpPgAdmin so that the changes take place:

systemctl restart postgresql
systemctl restart apache2
systemctl enable postgresql
systemctl enable apache2

Step 6. Accessing phpPgAdmin.

phpPgAdmin will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/phppgadmin or http://server-ip/phppgadmin. If you are using a firewall, please open port 80 to enable access to the control panel.
phppgadmin-ubuntu-16.04

Congratulation’s! You have successfully installed PostgreSQL Server. Thanks for using this tutorial for installing PostgreSQL in Ubuntu 18.04 (Bionic Beaver) systems. For additional help or useful information, we recommend you to check the official PostgreSQL web site.

How To Install Joomla 3.9.5 on Ubuntu 18.04 LTS

Install Joomla on Ubuntu 18

Joomla is a free and open source popular content management that uses a PHP and a backend database, such as MySQL. It offers a wide variety of features that make it an incredibly flexible content management system right out of the box. Furthermore, there are hundreds of free extensions written for that allows users to extend its functionality and customize it to their own objectives. Continue reading “How To Install Joomla 3.9.5 on Ubuntu 18.04 LTS”