![]() ![]() Choose Add a device, and specify the name of the device, its IP address, and the SNMP information.This kind of template is applied to specific hosts to create RRD files. With the improved security in SNMPv3 you have to give more information.Ĭacti has a set of data templates that define the structure for storing objects’ data, and that recognize the most common hardware in practice, they use the MIB of the hardware. In particular, for devices that use SNMPv2, you have to give the SNMP community. To add a network device, you have to know its IP address and SNMP credentials. You should see information about your local machine, such as CPU usage and network traffic. Your local machine should already be listed, though when you first invoke Cacti no graphs may be ready, so wait a few minutes and check the graphs again. In Cacti, a device can be any hardware or software that can be monitored remotely or locally. Now you can work from the web interface to check graphs and add new devices to the Cacti installation. To determine which versions of RRDTool and net-snmp are installed on your system, use the commands: # rpm –qa net-snmp Note that during the installation you’ll be asked which versions of some packages are you using. You will be required to change this password immediately. Once it finishes successfully you can log into Cacti with a username and password of admin. Now you can point your web browser to your-server/cacti/ to invoke a wizard that asks you if this is a new installation, and that verifies that all the variables and settings used by Cacti are correct (see figure below). This line tells cron to use the standard poller and gather data every five minutes. The Cacti application collects its data using a utility known as a poller. To have Cacti start gathering data, add a line to your /etc/crontab file similar to: */5 * * * * cactiuser php /usr/share/cacti/poller.php > /dev/null 2>&1 Execute this command from inside Cacti’s directory to change the permissions: # chown -R cactiuser rra/ log/ Next, set the appropriate permissions on Cacti’s directories for graph and log generation. Now edit /usr/share/cacti/include/config.php and specify the database type, name, host, user, and password for your Cacti configuration. Import the default Cacti database from the projects doc directory: # mysql cacti GRANT ALL ON cacti.* TO IDENTIFIED BY ' somepassword' Create the database with the command: # mysqladmin -user=root create cacti The Cacti installation procedure adds a configuration file for Apache – namely /etc/httpd/conf.d/nf – so you have to restart Apache with the command: # service httpd restartīefore you can use Cacti you must configure a MySQL database for it. # yum -y install php php-mysql php-snmp php-xml Now you can use yum as root to install all of the necessary packages: # yum -y install httpd Then update the system with the command # yum update. ![]() If you have a 64-bit system, run: # rpm -ivh To install it on a 32-bit system, run: # rpm -ivh The command to add EPEL differs depending on your server’s CPU hardware architecture. If the output is a blank line, you probably don’t have it. If you are unsure about whether you have EPEL installed, run the command # rpm -qa |grep -i epel. If you don’t already have EPEL among your sources you can add it easily. ![]() Apache, PHP, and MySQL are available in the standard CentOS repository, while RRDTool is available in EPEL (Extra Packages for Enterprise Linux), a repository that holds useful packages for Red Hat Enterprise Linux-based distributions, including CentOS. ![]() To run properly, Cacti need a complete LAMP stack and RRDTool installed. To see how Cacti and RRDTool can help monitor devices on a network, we’ll use CentOS 6 as our server platform. It supports data gathering via different methods such as scripts in any language and SNMP. Cacti provides templates to gather and show information such as system load (CPU, RAM, disks), users connected, MySQL load, and Apache load, all of which can affect the performance of your site.Ĭacti’s front end is completely PHP-driven. RRDTool stores all of the necessary information to create graphs and populate them with data in a MySQL database. Cacti was developed specifically to monitor and collect performance information, while Nagios is more oriented toward state changes, such as noting whether a daemon is up or down. While the popular Nagios application is a good general-purpose monitoring program that you can extend with plugins to handle just about any task, you may do even better by employing Cacti as a graphical front end to RRDTool‘s data logging and graphing functionality. This is an article of mine, first published on WaziĮvery organization must monitor its infrastructure’s uptime and performance. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |