Monitor your network using cacti (5)-cacti plug-in

Source: Internet
Author: User
Tags rrdtool

I,CactiPlug-ins

 

The cacti plug-in is an extension of cacti.

To use the cacti plug-in, you must first extend the cacti architecture to support the plug-in.

1.  Install cacti plug-in architecture Extension

: Http://cactiusers.org/downloads/patches/

The current version is V1.1 and is designed specifically for cacti v0.8.6.

1) decompress the downloaded tar package and you will get a cacti-plugin-arch directory.

# Tar-zxvf cacti-plugin-arch.tar.gz

# Cd cacti-plugin-arch

# Ls

2 ). there are two methods to install cacti plug-in architecture extension. The first method is to use the patch file, which contains the differences between the original file and the modified file, therefore, you can use the patch file to obtain the new file. The second method is to use the pre-patched file to directly overwrite the files in the files-0.8.6 * directory corresponding to cacti. Choose to use the patch file for installation (this is also recommended on the official website ). Copy the cacti-pligin-0.8.6 *. Diff file of the corresponding version of cacti to the cacti directory and install it using the patch command.

# Cp cacti-plugin-0.8.6j.diff/usr/local/Apache/htdocs/cacti

// Back up the cacti directory so that the plug-in extension can be restored to the original state after the installation fails.

# Cd/usr/local/Apache/htdocs

# Cp-r cacti./cacti. Bak

# Cd./cacti

// Use the following command to test

#Patch-P1-n -- dry-run <cacti-plugin-0.8.4.7. Diff

//After the preceding command is successful, run the following command to install

# Patch-P1-n <cacti-plugin-0.8.4.7. Diff

3 ). after the configuration is installed, first check your cacti configuration file to see if cacti-related database information is overwritten. If so, copy a copy from the backup file directly to the configuration file directory.

# CP ../include/config. php./include/config. php

Open the cacti configuration file and find the following options:

$ Config ['url _ path'] = "/";

If your cacti can be directly accessed in a browser using the following methods, you do not need to modify the cacti configuration file.

Http://www.youdomain.com or

Http: // ip address of the cacti Machine

          If cacti is directly accessed in a browser using the following methods,

          Http://www.youdomain.com/cacti or

          Http: // ip address of the cacti machine/cacti

Then$ Config ['url _ path'] = "/";Must be modified$ Config ['url _ path'] ="/Cacti/";

          Note that the forward and backward/cannot be lost.

          Now that the cacti plug-in structure has been extended, you can download and install the required cacti plug-in.

     

1.  Install plug-ins

It is easy to install, upgrade, and remove plug-ins. You must install the cacti plug-in structure extension before installing the plug-ins.

1) download the plug-in. Here, we use the monitor plug-in as an example.

     Monitor plug-in: http://cactiusers.org/downloads/

     Decompress the downloaded tar package.

     #Tar-zvcf monitor-0.7.tar.gz

      After decompression, you will getMonitorDirectory.

2).InstallMonitor, You only needMonitorCopy directoryCacti/plugins/Directory. If you are upgrading and installing, you only need to completely overwrite the originalMonitorDirectory.

3).ActivateMonitorPlugin, modifyCactiConfiguration file (CactiDirectoryInclude/config. php). Search in configuration$ Plugins = array ();Line, which is added below this line:

$ Plugins [] ='Monitor';

Note: The name of the above monitor must be the same as that of the plug-in directory under cacti/plugins.

4) Some plug-ins require additional configuration. Please configure the plug-ins according to the plug-in installation documentation, which is described here.

5) When removing a plug-in, you only need to modify the cacti configuration file and comment out the lines related to the plug-in.

For example:

           //$ Plugins [] ='Monitor';

6) under the console tab, click the settings link in the left menu, and click the MISC option card on the web page that appears on the right to configure the monitor plug-in.

 

As shown in the following figureMonitorThe status of the monitored machine under the tab. When machines existDownThe machine icon changes from green to red and generates an alarm.

3. Install the threshold plug-in
V0.3.5.1Edition: http://download.cactiusers.org/downloads/thold.gzip
V0.3.5.1The version is the latest version. This version has some problems when installing on cacti v0.8.4.7, and some functions cannot be found.V0.3.4.
V0.34Edition: http://cactiusers.net/downloads/plugins/thold-0.3.4.tar.gz

1) install the threshold plug-in. You only need to copy the extracted thold directory to the cacti/plugins/directory and modify the cacti configuration file (include/config. php under the cacti directory ). Find the $ plugins = array (); line in the configuration, and add it below this line:
$ Plugins [] = 'thold ';
Refresh the cacti homepage and you will see an additional threshld tab.
Is the cacti interface after the threshold plug-in and monitor plug-in are added:

Select the console tab, click Settings in the left menu, and then click the alerting/thold tab to set the threshold plug-in.


Click threshold templates in the left-side menu under the console tab.

Click Add to add a threshold template.

Here, we will add a threshold template to monitor hard disk space.

Select hdd_free in the data field drop-down box and click go.

 

Fill in the following information and enter 1000 in the low threshold text box, which means to send an email alarm when the remaining hard disk space is less than MB. In the threshold cdef drop-down box, select divide by 1024 and fill in the alert email box to complete the addition of the threshold template.

 

Apply the created threshold template. On the console tab, click devices, select the host to which the template is applied, and click the topCreate graphs for this hostClick the auto-create thresholds link to apply the created threshold template.

 

After setting, click thresholds in the left-side menu under the console tab.

 

You can manage created alarms here.

 

Click the threshld tab to view the trigger status of the alarm.

 

 

4. Other plug-ins

Other plug-ins can be installed at http://cactiusers.org/downloads.

1). Discovery: This plugin adds the ability to auto-discover devices on a subnet that are not monitored by cacti and tells you if they are SNMP enabled.

2). flowviewer: A simple viewer for viewing reports based on data from flows created by NetFlow.

3). Mac track: The Mac track plugin for cacti by the witness.

4). Settings: This plugin houses common settings and functions used by different plugins.

5). Network weathermap: This is a complicated cacti plug-in. It requires the support of the GD library. You can refer to the cacti installation Section to support the GD library. You can use it to draw beautiful network conditions.

Official Website Description: http://www.network-weathermap.com/node/79

: Http://www.network-weathermap.com/download

Installation Method:

Http://www.network-weathermap.com/manual/0.92/pages/install-cacti-editor.html

 

Ii. References

 

Cacti Official Website: http://www.cacti.net/index.php

Cacti official website forum: http://forums.cacti.net/

Cacti documentation: http://docs.cacti.net/

Cacti plug-in: http://cactiusers.org/index.php

Network weathermap: http://www.network-weathermap.com/

Rrdtool Official Website: http://oss.oetiker.ch/rrdtool/

NET-SNMP Official Website: http://www.net-snmp.org/

Apache Official Website: http://httpd.apache.org/

MySQL Official Website: http://www.mysql.com/

PHP Official Website: http://www.php.net/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.