Tutorial How to Install and Configure MRTG on Debian 10

Tutorial How to Install and Configure MRTG Monitoring in Debian 10 – MRTG (the Multi Router Traffic Grapher) Is an application used to monitor traffic loads on network links. MRTG will create HTML pages containing GIF images that illustrate traffic through the network on a daily, weekly, monthly and yearly basis. Well, before you have made several service or hosting services, you can check the Debian category. This monitoring is very necessary if friends as admin because it is to check how the condition of the Debian Linux Server or Router to be monitored. If later after installing this monitoring you are still confused of its use, you can check the MRTG Documentation provided in detail, check the official MRTG Monitoring website. Okay that’s all a little explanation about these tools and then just step by step installation.

Tools and materials :

  • Debian OS (10)
  • DVD 1,2,3

Time period :

  • For about 1-5 minutes time is complete

Work Stage to MRTG Installation and Configuration in Debian based Distributions

1. Apache2 & Snmp

The first step, Installing a web service package that is Apache2. Continue to install the monitoring protocol, SNMP. Well these two are needed to build MRTG monitoring. To install the two packages with the command:

2. Backup SNMP files

The second step, to overcome the error script or snmpd.conf file, we first backup with the command “cp /etc/snmp/snmpd.conf /etc/snmp/snmpd.conf.default“. Now after has been backup then edit the file “snmpd.conf” with the text edit “nano /etc/snmp/snmpd.conf“. Then move the pager (#) in the “rocomunity public localhost” line and then edit the text in the “sysLocation” and “sysContact” lines with the following picture.

3. Restart SNMP

The third step, if the file has been edited then restart the SNMP serive with the command “/etc/init.d/snmpd restart” if it appears “OK” means it works. Then check if the snmpd service is running with the following command install mrtg.

4. Install MRTG monitoring

Fourth step, after setting SNMP then we set MRTG according to the topic of this article title. to install the tool with the command “apt-get install mrtg” when the installation process is complete then create a folder or directory mrtg with the following command:

5. Rework file mrtg.cfg

Five step, after that you can direct to “/var/www/html/mrtg“and for edited file mrtg.cfg with command “nano /etc/mrtg.cfg” then try to edit on line “for Debian“.

6. Cfgmaker & Indexmaker

The sixth step, cfgmaker command so that our server as if localhost becomes public according to the mrtg.cfg file settings later. Then the indexmaker can be displayed on the MRTG web console with a web browser.

Type command: “cfgmaker public@localhost > /etc/mrtg.cfg“.

(MRTG Installation and Configuration in Debian based Distributions)

Command for indexmaker “indexmaker /etc/mrtg.cfg >> /var/www/html/mrtg/index.html“.

7. Add rc.local

The seventh step, add the script so that the server when the first starup directly runs the script in the file “rc.local” following the edit command “nano /etc/rc.local”. Don’t forget to add a script like this:

8 Finish

Finally we also install MRTG Monitoring on Debian 10 (stretch) with ease tutorial. To display the web console in the browser, call “http: // ip_address_server / mrtg”.

mrtg

About the author: admin

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *