Installing MRTG

Topic Location: Monitoring the IMG > MRTG

Prerequisite

Upgrade GCEMS to the latest version (minimum of GCEMS 10.3.1.121)

 

(Note: If using 10.5.1 + software the cantata folder will be changed to dialogic)

 

Procedure:

  1. Login as root

  2. Go to the following directory: /usr/local/src

  3. Run the installMrtg.sh script

    ./installMrtg.sh
     

  4. Verify contents of directory by typing:

    ls

    there should be 5 directories:

    gd
    libpng
    zlib
    mrtg
    tarFiles
     

  5. Start GCEMS

  6. Create the MRTG configuration file and HTML files

  1. Setup an MRTG Web Host. See Setting Up An MRTG Web Host.

 

Troubleshooting

 

Are the mrtg output files in the directory?

  1. Go to directory

    /opt/ dialogic/common/mrtg_logs (Software 10.5.0)
     

  2. Enter the ls command

  3. There should be many . png and .html files

 

Is MRTG installed correctly?

  1. Go to directory /usr/local/src

  2. Enter the ls command 'ls'

PATH=$PATH:/usr/bin

 

 

Are the Stats Files being created?

  1. Go to directory

    /opt/dialogic/common/stats
     

  2. Show the directory contents by entering the following command:

ls

Verify there are a number of .csv files. If one of the .csv files is opened, there should be entries for that variable printed every 5 minutes.

 

 

Is the stats frequency setup correctly?

  1. Go to directory

    /opt/dialogic/common (Software 10.5.0)
     

  2. Edit the Defaults file – the file should have the following line in it

    STATS_FREQUENCY:5
     

  3. If it is not set correctly change it and restart the GCEMS.

 

 

Check the cronjob

  1. Open the cronjob file by typing:

crontab –l

You should see a line like the following:

*/5 * * * * env LANG=C /usr/local/src/mrtg/bin/mrtg /opt/dialogic/common/mrtg_bin/dialogicmrtg.cfg -- logging /opt/dialogic/common/log/mrtg.log > /dev/null 2>&1

 

 

Manually starting the Cronjob if needed

  1. Type the following:

crontab<<EOF

*/5 * * * * env LANG=C /usr/local/src/mrtg/bin/mrtg /opt/dialogic/common/mrtg_bin/dialogicmrtg.cfg -- logging /opt/dialogic/common/log/mrtg.log > /dev/null 2>&1 EOF

 

 

Verify the mrtg_bin and mrtg_logs directories have write access

  1. Go to directory:

    /opt/dialogic/common (Software 10.5.0)
     

  2. Show all directory settings by typing:

    ls -al
     

  3. If all the directories do not have read/write/execute privileges change it

    Login as ROOT
    chmod 777 mrtg_bin
    chmod 777 mrtg_log

 

 

Verify the dialogicmrtg.cfg was created

  1. Go to directory:

    /opt/dialogic/common/mrtg_bin (Software 10.5.0)
     

  2. Show the directory contents by typing:

    ls
     

  3. Make sure there is a file called dialogicmrtg.cfg

If this file is not here, then see step 3 of the installation section.