Tutorial Ubuntu 20.04 LTS : Cara Install Cacti Monitoring Tools
Cacti merupakan salah satu monitoring tools yang sering dan sangat banyak digunakan untuk melakukan monitoring system. Terutama untuk Monitoring System, Network Traffic, Network Device, Bandwidth, dan lain-lain. Kali ini kita akan melakukan instalasi Cacti Monitoring Tools pada Ubuntu Server 20.04 LTS.
Install
Sebelum melakukan instalasi terlebih dahulu lakukan update dan upgrade sistem.
$ sudo apt update && sudo apt upgrade
Install MariaDB
Karena Cacti memerlukan mysql database maka kita harus menginstalnya, disini kita menggunakan mariadb
database.
$ sudo apt install -y mariadb-server
Lakukan instalasi mariadb menggunakan perintah berikut. Jangan lupa untuk melakukan set root password.
$ sudo mysql_secure_installation
NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
In order to log into MariaDB to secure it, we'll need the current
password for the root user. If you've just installed MariaDB, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.
Enter current password for root (enter for none): [enter]
OK, successfully used password, moving on...
Setting the root password ensures that nobody can log into the MariaDB
root user without the proper authorisation.
Set root password? [Y/n] Y
New password:
Re-enter new password:
Password updated successfully!
Reloading privilege tables..
... Success!
By default, a MariaDB installation has an anonymous user, allowing anyone
to log into MariaDB without having to have a user account created for
them. This is intended only for testing, and to make the installation
go a bit smoother. You should remove them before moving into a
production environment.
Remove anonymous users? [Y/n] Y
... Success!
Normally, root should only be allowed to connect from 'localhost'. This
ensures that someone cannot guess at the root password from the network.
Disallow root login remotely? [Y/n] Y
... Success!
By default, MariaDB comes with a database named 'test' that anyone can
access. This is also intended only for testing, and should be removed
before moving into a production environment.
Remove test database and access to it? [Y/n] Y
- Dropping test database...
... Success!
- Removing privileges on test database...
... Success!
Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.
Reload privilege tables now? [Y/n] Y
... Success!
Cleaning up...
All done! If you've completed all of the above steps, your MariaDB
installation should now be secure.
Thanks for using MariaDB!
Install Cacti
Untuk memulai instalasi cacti dapat menggunakan perintah berikut.
$ sudo apt install -y cacti
Secara default cacti akan melakukan instalasi packet web server apache dan php. Maka jika muncul prompt berikut kita pilih apache2
Package configuration
┌─────────────────────────┤ Configuring cacti ├──────────────────────────┐
│ Please select the web server for which Cacti should be automatically │
│ configured. │
│ │
│ Select "None" if you would like to configure the web server manually. │
│ │
│ Web server: │
│ │
│ apache2 │
│ lighttpd │
│ None │
│ │
│ │
│ Ok │
│ │
└────────────────────────────────────────────────────────────────────────┘
Configure Database Cacti, Pilih Yes
.
Package configuration
┌───────────────────────────┤ Configuring cacti ├───────────────────────────┐
│ │
│ The cacti package must have a database installed and configured before │
│ it can be used. This can be optionally handled with dbconfig-common. │
│ │
│ If you are an advanced database administrator and know that you want to │
│ perform this configuration manually, or if your database has already │
│ been installed and configured, you should refuse this option. Details on │
│ what needs to be done should most likely be provided in │
│ /usr/share/doc/cacti. │
│ │
│ Otherwise, you should probably choose this option. │
│ │
│ Configure database for cacti with dbconfig-common? │
│ │
│ Yes No │
│ │
└───────────────────────────────────────────────────────────────────────────┘
Buat password database untuk cacti.
Package configuration
┌────────────────────────┤ Configuring cacti ├────────────────────────┐
│ Please provide a password for cacti to register with the database │
│ server. If left blank, a random password will be generated. │
│ │
│ MySQL application password for cacti: │
│ │
│ *****______________________________________________________________ │
│ │
│ Ok Cancel │
│ │
└─────────────────────────────────────────────────────────────────────┘
Konfirmasi password.
Package configuration
┌────┤ Configuring cacti ├─────┐
│ │
│ │
│ Password confirmation: │
│ │
│ *****_______________________ │
│ │
│ Ok Cancel │
│ │
└──────────────────────────────┘
Tunggu proses instalasi hingga selesai.
Pengujian
Setelah proses instalasi selesai kita dapat melakukan akses menuju dashboard cacti dengan cara melakukan akses http://ip-server/cacti
. Untuk login default username adalah admin
dan passwordnya adalah yang kita buat saat melakukan instalasi cacti tadi.
Cacti Dashboard
Sampai disini kita sudah berhasil melakukan instalasi Cacti Monitoring Tools pada Ubuntu Server 20.04 LTS dan tentunya siap untuk dikonfigurasi. Happy Config!! 😉