development blog for the wicked stuff we encounter

I've added MRTG to Cron, but later I found that it is not running. Checking the logs, and found the following: <code> ERROR: Creating templock /var/lock/mrtg/_etc_mrtg.cfg_l_3723: No such file or directory at /usr/bin/mrtg line 1757 </code> The folder doen not exist, so <code>mkdir -m 0755 /var/lock/mrtg</code>...

Comments

Comment by kurt

I had to put the path to the mrtg.cfg in cron.

env LANG=C /usr/bin/perl /usr/local/mrtg-2/bin/mrtg /usr/local/mrtg-2/mrtg.cfg --logging /var/log/mrtglog

kurt
Comment by Jason

I went with the solution Kurt had. It worked great. Thanks for the info!!

Jason
Comment by kurt

I had to put the path to the mrtg.cfg in cron.

env LANG=C /usr/bin/perl /usr/local/mrtg-2/bin/mrtg /usr/local/mrtg-2/mrtg.cfg --logging /var/log/mrtglog

kurt
Comment by Jason

I went with the solution Kurt had. It worked great. Thanks for the info!!

Jason