Monday, August 31, 2026

Linux | Install Joomla with Nginx on Ubuntu 24.04 Server

This guide explains how to install and secure the Joomla open-source CMS on an Ubuntu 24.04 server using a LEMP stack (Nginx, MariaDB, and PHP-FPM) with HTTPS encryption.

Prerequisites

To complete this guide, make sure you have the following:

  • An Ubuntu 24.04 server.
  • A non-root user with administrator privileges.
  • A domain name pointed to a server IP address.

Installing dependencies

Joomla is a PHP-based content management system. To install it, you must install PHP on your system. In this section, you'll be installing the LEMP Stack (Linux, Nginx, MariaDB, and PHP-FPM) as dependencies for Joomla.First, run the command below to update your Ubuntu package index.

sudo apt update


Install the LEMP Stack dependencies with the command below. Enter 'Y' to confirm the installation.

sudo apt install nginx mariadb-server php-fpm php-curl php-common php-json php-intl php-xml php-gd php-mysql php-imagick php-mbstring php-zip


After the installation is completed, check the Nginx service status with the following:

sudo systemctl is-enabled nginx
sudo systemctl status nginx

You can see Nginx service is running.


Now check the MariaDB service to ensure that the service is running and enabled with the command below:

sudo systemctl is-enabled mariadb
sudo systemctl status mariadb


Lastly, run the following command to verify the PHP-FPM service. The PHP-FPM should be running by default on the sock file.

sudo systemctl is-enabled php8.3-fpm
sudo systemctl status php8.3-fpm


Configuring PHP-FPM

Now that the LEMP Stack is installed, you'll configure PHP-FPM installation and change some default configurations as needed for Joomla.

Open the PHP-FPM configuration '/etc/php/8.3/fpm/php.ini' with the 'nano' editor.

sudo nano /etc/php/8.3/fpm/php.ini

Change the default configuration with the following:

memory_limit=512M
upload_max_filesize=64M
post_max_size=64M
max_execution_time=120
output_buffering = Off
extension=intl

Save the file and exit the editor.

Now restart the PHP-FPM service to apply your changes.

sudo systemctl restart php8.3-fpm

Lastly, you can check the PHP sock file for the PHP-FPM service with the command below.

ss -pl | grep php

You can see below the sock file for PHP-FPM is located at the '/var/run/php/php8.3-fpm.sock'.


Configuring MariaDB server

In this section, you'll secure the MariaDB server installation, and then create a new database and user for Joomla. You'll be using the 'mariadb-secure-installation' to secure the MariaDB server, and then through the 'mariadb' client to create a new database and user.

To secure the MariaDB server, run the 'mariab-secure-installation' command below.

sudo mariadb-secure-installation

Now you'll be asked to set up the MariaDB server with the following:

  • For the default MariaDB server installation without a root password, press ENTER when asked about the password.
  • The local authentication for MariaDB root users is secured by default, input 'n' when asked to change the authentication method to 'unix_socket'.
  • Input 'Y' to create a new MariaDB root password. Then, input the strong password for your MariaDB root user and repeat.
  • When asked to disable remote authentication for the MariaDB root user, input 'Y' to agree.
  • The default MariaDB server installation comes with the database 'test' and allows an anonymous user to access it.
  • Input 'Y' for both settings to remove the default database 'test' and remove the anonymous privilege.
  • Lastly, input 'Y' to confirm reloading table privileges.

Once the MariaDB is secured, you'll create a new database and user for Joomla.

Log in to the MariaDB server with the 'mariadb' command below. Enter your MariaDB root password when prompted.

sudo mariadb -u root -p

Now run the following queries to create a new database 'joomladb', and a new user 'joomla' with the password 'p4ssword'.

CREATE DATABASE joomladb;
CREATE USER joomla@localhost IDENTIFIED BY 'p4ssword';
GRANT ALL PRIVILEGES ON joomladb.* TO joomla@localhost;
FLUSH PRIVILEGES;


Next, run the query below to check privileges for user 'joomla'. You'll see the 'joomla' user can access the database 'joomladb'.

SHOW GRANTS FOR joomla@localhost;

Lastly, type 'quit' to exit from the MariaDB server.


Downloading Joomla source code

At this point, you've installed and configured dependencies for Joomla. Now you'll download the Joomla source code and set up the document-root/webroot directory for Joomla installation.

Go to the '/var/www' directory and download the Joomla source code with the 'wget' command below. Check the Joomla download page and grab the link for the latest version.

cd /var/www/
wget https://downloads.joomla.org/cms/joomla5/5-1-4/Joomla_5-1-4-Stable-Full_Package.zip

Now run the 'unzip' command below to extract the Joomla source code to the 'joomla' directory.

unzip Joomla_5-1-4-Stable-Full_Package.zip -d joomla

Lastly, run the 'chmod' command below to change the ownership of the '/var/www/joomla' directory to the user 'www-data'.

sudo chown -R www-data:www-data /var/www/joomla

Setting up Nginx server block

Now you'll be creating a new Nginx server block configuration for running Joomla. So make sure that you've your domain name ready and pointed to the server IP address.

Create a new Nginx server file '/etc/nginx/sites-available/joomla' with the following 'nano' editor.

sudo nano /etc/nginx/sites-available/joomla

Insert the configuration below and change the 'server_name' option with your domain name.

server {
listen 80;
server_name howtoforge.local;
server_name_in_redirect off;

access_log /var/log/nginx/localhost.access_log;
error_log /var/log/nginx/localhost.error_log info;

root /var/www/joomla;
index index.php index.html index.htm default.html default.htm;

# Support API
location /api/ {
try_files $uri $uri/ /api/index.php?$args;
}

# Support Clean (aka Search Engine Friendly) URLs
location / {
try_files $uri $uri/ /index.php?$args;
}

# add global x-content-type-options header
add_header X-Content-Type-Options nosniff;

# deny running scripts inside writable directories
location ~* /(images|cache|media|logs|tmp)/.*\.(php|pl|py|jsp|asp|sh|cgi)$ {
return 403;
error_page 403 /403_error.html;
}

location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.3-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include /etc/nginx/fastcgi.conf;
}

# caching of files
location ~* \.(ico|pdf|flv)$ {
expires 1y;
}

location ~* \.(js|css|png|jpg|jpeg|gif|swf|xml|txt)$ {
expires 14d;
}

}

Save the file and exit the editor.

Now run the command below to activate the 'joomla' server block and verify your Nginx configuration. If you've proper Nginx settings, you'll see an output 'Syntax is OK'.

sudo ln -s /etc/nginx/sites-available/joomla /etc/nginx/sites-enabled/
sudo nginx -t

Lastly, run the 'systemctl' command below to restart the Nginx service and apply your changes.

sudo systemctl restart nginx


Securing Joomla with HTTPS

In this guide, you'll secure Joomla with HTTPS. If you're using the public domain, you can secure Joomla through SSL/TLS certificates via Certbot and Letsencerypt.

Install 'Certbot' and the Certbot Nginx plugin with the 'apt' command below. Input 'Y' to confirm the installation.

sudo apt install certbot python3-certbot-nginx

After the installation is complete, run the following 'certbot' command to generate SSL/TLS certificates and secure your Joomla installation with HTTPS. Make sure to change the domain name and email address with your information.

sudo certbot --nginx --agree-tos --redirect --hsts --staple-ocsp --email kyrie@howtoforge.local -d howtoforge.local

When finished, your Joomla installation is secured with HTTPS through SSL/TLS certificates from Letsencrypt.

Installing Joomla

Open your web browser and visit your Joomla domain name such as https://howtoforge.local/. You'll see the Joomla installation wizard.

Select your default language and enter your site name.


Enter the new admin user, email, and password for Joomla.


Enter details of your MariaDB database and user, then click 'Install Joomla' to proceed with the installation.


After the installation is complete, click the 'Open Site' to open the default homepage, or 'Open Administrator' to access the Joomla administration dashboard.


For the default Joomla homepage, you'll see the following.


Now enter your admin user and password and click 'Login'.


If you've the correct user and password, you'll see the following Joomla administration dashboard.


Conclusion

You've successfully installed Joomla on Ubuntu 24.04 using Nginx, MariaDB, and PHP-FPM, and secured your site with free HTTPS via Certbot and Let's Encrypt.

Linux | Install nTopng on Debian 12

Ntopng is an open-source tool for real-time network traffic analysis and historical monitoring across multiple platforms (Linux, Windows, MacOS). This tutorial guides you through installing Ntopng on Debian 12, enabling features like Network Discovery and Active Monitoring, and tracking live interface traffic on the dashboard.

Prerequisites

Before you begin, make sure you have the following:

  • A Debian 12 server
  • A non-root user with administrator privileges

Installing Ntopng

To install Ntopng, you must add the official repository and install it through the APT package manager. After the installation is finished, you must ensure that the 'ntopng' service is running using the 'systemctl' command, or you can use the 'ss' command to check the list of open ports on your system. If Ntopng runs, you'll see that port '3000' with the status 'Listened'.

First, run the command below to update your Debian package index and install the 'software-properties-common' and 'wget' packages. When prompted, enter 'Y' to confirm with the installation.

sudo apt update
sudo apt install software-properties-common wget


Download the Ntopng repository for Debian using the 'wget' command below. And then, install the package repository using the 'apt' command.

wget https://packages.ntop.org/apt/bookworm/all/apt-ntop.deb
sudo apt install ./apt-ntop.deb


Once the Ntopng repository is added to your system, execute the following 'apt' command to refresh your package and install the 'ntopng' package.

sudo apt update && sudo apt install ntopng

Input 'Y' to confirm with the installation.


After the installation is complete, run the 'systemctl' command below to check and verify the 'ntopng' service status.

sudo systemctl is-enabled ntopng
sudo systemctl status ntopng

In the output below, you can see that Ntopng is running and enabled on your Debian system.


Lastly, you can also check the Ntopng port with the 'ss' command below. You'll see the Ntopng process uses port 3000.

ss -tulpn


Configuring Ntopng

After you've installed Ntopng, you'll configure it to monitor your networks. In this example, we'll monitor two network interfaces for both local and public interfaces. To do that, you must edit the Ntopng config file '/etc/ntopng/ntopng.conf'.

Open the default Ntopng config file '/etc/ntopng/ntopng.conf' using the 'nano' editor.

sudo nano /etc/ntopng/ntopng.conf

Add your network interface to the '-i' option and specify the port for Ntopng. In this example, we'll monitor interfaces eth0 and eth1, then run Ntopng on default port 3000.

# Network interface
-i=eth0
-i=eth1
# Web server port
-w=3000

Save the file and exit the editor.

Now open the file '/etc/ntopng/ntopng.start' with the 'nano' editor.

sudo nano /etc/ntopng/ntopng.start

Enter your local network subnet to the '--local-networks' like the following:

--local-networks "192.168.1.0/24"
--interface 1

When done, save and exit the file.

Lastly, run the 'systemctl' command below to restart the 'ntopng' service and apply your changes.

sudo systemctl restart ntopng

Logging in to Ntopng

Now that you've configured Ntopng, let's access our installation through a web browser.

Open your web browser and visit your server IP address followed by port 3000, ex: http://192.168.10.60:3000/. If your installation is successful, you'll see the Ntopng login page.

Log in with the default user 'admin' and password 'admin'.


Now, you'll be asked to change the default Ntopng password. Make sure to use the strong password for the Ntopng dashboard authentication.


If successful, you'll see the Ntopng dashboard like the following:


Enable Network Discovery on Ntopng

In this section, you'll learn how to enable Network Discovery on the Ntopng. With this feature, the Ntopng will automatically identify live hosts within your network.

Click on the 'Settings > Preferences' and select 'Network Discovery'.

Turn on the 'Network Discovery' and click 'Save'.


To access Network Discovery on ntopng, select 'Dashboard > Network Discovery' and click 'Run Discovery'. You can see below that Ntopng automatically detects hosts within the network.


Setting up Active Monitoring with Ntopng

Now that you've enabled Network Discovery, let's turn on the 'Active Monitoring' feature and set up active monitoring to monitor our host. In this example, you'll be using ICMP measurement to monitor if the host is alive or not.

To monitor target hosts, Ntopng can use the following protocols:

  • ICMP and ICMPv6: to check host IP reachability.
  • HTTP and HTTPS: to check functionalities of possible host web servers.
  • Throughput: to check the Internet throughput.
  • Speedtest: to check for Internet bandwidth.

Click on the 'Settings > Preferences' and select 'Active Monitoring'.

Toggle the 'Active Monitoring' option and click 'Save' to confirm.


Next, click on 'Monitoring > Active Monitoring' and click the '+' button to add new active monitoring.


In this example, we'll monitor our host '192.168.10.41' through the ICMP or ping, click 'Add' to confirm.

You can see below the active monitoring for host '192.168.10.41' is created.


Checking the Live Traffic from Ntopng

Now that you've learned how to set up Network Discovery and enable Active Monitoring, let's see your network traffic live from the Ntopng dashboard.

Click on the 'Flow > Live' menu and you'll see the live traffic of your network. Select your specific network interface from the top menu. In the example below, you can see the external traffic of the server on interface 'eth0'.


Conclusion

You've successfully installed Ntopng on Debian 12 and learned how to use it to automatically discover live network hosts, enable active monitoring, and track host/server status.

Linux | Install and Use Nessus Vulnerability Scanner on Ubuntu 24.04

Nessus is a network scanning tool and vulnerability scanner developed by Tenable. It is used for vulnerability assessments, penetration testing, and ethical hacking. Nessus builds one of the most comprehensive vulnerability scanners on top of CVE (Common Vulnerabilities and Exposures) architecture. With Nessus, you can identify security weaknesses in devices, applications, and operating systems.

In this guide, you'll learn how to install Nessus on Ubuntu 24.04 server. You'll also learn how to set up Nessus using the installation wizard, add Nessus bin directories to the system PATH, create your first Nessus scan, and generate HTML reports of your scan result.

Prerequisites

To begin with this guide, make sure you have the following:

  • An Ubuntu 24.04 Server

  • A non-root user with administrator privileges


Installing Nessus via DEB File

To install Nessus on a Linux system, you can easily download the package (DEB or RPM), and then install it manually through the 'dpkg' command for Debian-based or 'rpm' for the RedHat operating system. Lastly, you can start the Nessus service via 'systemctl'.

Download the Nessus DEB file using the 'curl' command below. Make sure to visit the Nessus download page to get the latest version.

curl --request GET \
--url '<https://www.tenable.com/downloads/api/v2/pages/nessus/files/Nessus-10.8.3-ubuntu1604_amd64.deb>' \
--output 'Nessus-10.8.3-ubuntu1604_amd64.deb'

Once downloaded, run the 'dpkg' command below to install Nessus via the DEB file.

sudo dpkg -i Nessus-10.8.3-ubuntu1604_amd64.deb


After the installation is finished, run the following 'systemctl' command to start and enable the 'nessusd' service. And then, check it to ensure the service is running.

sudo systemctl enable --now nessusd
sudo systemctl status nessusd

In the output below, you can see that 'nessusd' is enabled and running.


Setting up UFW (Uncomplicated Firewall)

Now that you've Nessus running, let's configure the UFW (Uncomplicated Firewall) and open ports for OpenSSH and port '8834/tcp' for the Nessus dashboard.

Run the 'ufw' command below to enable the 'OpenSSH' profile for allowing SSH access, then open port '8834/tcp' for the Nessus web application.

sudo ufw allow OpenSSH
sudo ufw allow 8834/tcp

Now run the command below to start and enable UFW, and then enter 'y' to confirm. You'll get an output such as 'Firewall is active and enabled on system startup'.

sudo ufw enable


Lastly, check the UFW with the following command. You'll see that UFW with the status 'active' and allowed access to the 'OpenSSH' and port '8834/tcp'.

sudo ufw status


Nessus Installation Wizard

Now that you've opened port '8834/tcp', you're ready to set up the Nessus installation wizard from your web browser.

Open your web browser and visit https://192.168.10.60:8834. If your Nessus installation is successful, you'll get the Nessus installation wizard.

Click 'Continue' to start the Nessus configuration.


Register to Tenable by entering your first and last name, and email address. The activation code will be sent to your email, so make sure to use the proper email.


When activated, you'll see the following:


Now enter your username and password that will be used to log in to the Nessus dashboard.


Next, the installation should begin. This Nessus downloads plugins that are needed.


After the process is finished, you'll be prompted with the Nessus authentication page. Enter your username and password, then click 'Sign In'.


If you have the correct credentials, you'll see the following Nessus dashboard.


If the plugin installation fails, you can install Nessus plugins through the 'nessuscli' utility.

cd /opt/nessus/sbin
./nessuscli update

Adding Nessus to System PATH

By default, Nessus is installed in the '/opt/nessus' directory. There are also two bin directories for the Nessus command. In this section, you'll add the Nessus bin directory to the system PATH via the '~/.bashrc' file.

Open the '~/.bashrc' file with the 'vim' editor.

vim ~/.bashrc

Paste the following configuration to add Nessus binary path '/opt/nessus/bin' and '/opt/nessus/sbin' to the system PATH.

export $PATH:/opt/nessus/bin:/opt/nessus/sbin

Save the file and exit the editor.

Now run the command below to reload the '~/.bashrc' file to the current session and check your system PATH. You'll see directories '/opt/nessus/bin' and '/opt/nessus/sbin' available in the PATH.

source ~/.bashrc
echo $PATH

You can now run the 'nessuscli' command like any other command. The below command will show your full path of the 'nessuscli' and 'nessusd' binary files.

which nessuscli
which nessusd


Scanning with Nessus

In this section, you'll learn how to scan with Nessus and generate HTML reports for your scanning. This section will be using the Nessus administration dashboard.

  • On the Nessus dashboard, click the New Scan button.

  • Select the Basic Network Scan template.


  • Enter your scan name, description, default folder to save your scan result, and the target IP address or hostname


  • Once created, click the play button to start the scan


  • After the scan, you can see the following result:


Click the 'Reports' menu to generate an HTML report of your scanning result. Below is our scanning result on the HTML page.


Conclusion

Congratulations! You've completed the installation of Nessus on the Ubuntu 24.04 server. You've also learned how to set up Nessus via the installation wizard and how to scan the host/system using Nessus. In addition to that, you've learned how to generate HTML reports of your scanning.