Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Is done in: https://github.com/schmto/nmsprime/blob/feature/install-schmto/modules/ProvMon/Install/after_install.sh

Manual: Installation + Configuration

Installation and configuration of cacti is done via the script installCacti.sh

...

  1. MySQL root password (to create the cacti DB)
  2. MySQL password of user 'cactiuser' which will be created, if necessary
  3. WebGUI password for user 'admin'

Available Modems are auto-detected and their corresponding graphs will be automatically created. 


Available CMTSs will also be added automatically. However, their interface graphs won't be automatically created, as we don't know which interfaces are of interest.

...

After 5 minutes the graphs should be shown in Laravel (Main Menu -> CMTS -> Analysis)

Spine

As per the default settings cacti uses cmd.php to query the devices. If cmd.php is to slow or doesn't work properly, one can use spine instead.

...

 
Code Block
titlecacti-spine.spec
collapsetrue

After building and installing (see Prime VoIP Monitoring) the package, one must set the Poller type from cmd.php to spine:

  1. Login into the cacti web interfaces as 'admin'
  2. Goto Console -> Settings -> Poller -> Poller Type -> spine
  3. "Save"

Modifying RRD files

Add two new datasets to exisiting RRD modem files to save incoming and outgoing traffic figures:

Code Block
for file in cm-*.rrd; do echo "$file" && rrdtool tune "$file" DS:ifHCInOctets:COUNTER:600:0:U DS:ifHCOutOctets:COUNTER:600:0:U; done

Regenerate Cable Modem definition in Cacti database

This is needed if we add a new graph (i.e. traffic diagram) in the cable modem device template. Only newly added modems would display the traffic diagram. In order to deploy the new diagram for all modems we can regenerate all modems with the following command:

Code Block
languagebash
php /usr/share/cacti/cli/remove_device.php --ip=cm-* --confirm
php /var/www/nmsprime/artisan nms:cacti

Especially the second command may take a while.

Develop with cactis script server

A good starting point is the Cacti Documentation for the script server. However for NMS Prime we made some adjustments. Following are the commands to test and develop scripts for the cacti script server.

Code Block
languagebash
titleDevelop with the cacti script server
# change user to apache
su -s /bin/bash apache
# start cacti script server
# make sure to restart after every code change
php /usr/share/cacti/script_server.php
# /var/www/nmsprime/modules/[Module]/Console/cacti/ss_[script_name].php [function] [hostname] [snmp_community]
# make sure to link the file to /var/lib/cacti/scripts/ss_[script_name].php
# example:
/var/www/nmsprime/modules/ProvMon/Console/cacti/ss_docsis.php ss_docsis cm-100096.demo.nmsprime.com