Ad blocker detected: Our website is made possible by displaying online advertisements to our visitors. Please consider supporting us by disabling your ad blocker on our website.
Thanks for the script! I've been working with this for a while, and have found some interesting things. The precompiled perfmon script above will only work with activestate perl 5.6, not the latest 5.8 version.
I don't have my Callmanagers connected to our active directory and it works fine. However I had to create a user with the same username and password on the CCM as the User that runs the poller. This is probably what is causing your problems.
I havent checked this thread in a long time, glad to see it got some interest and a port over to w32. I recently updated my script to reflect witch CCM the gateway was associated with.
While this info can be found out via the CCM interface and obviously perfmon (which is were I pull from) we wanted a way to just look in one spot at all gateways and see what CCM it was registered to and also how many calls in use. Here is what it looks like, if interested I can post the script but its pretty darn basic!
Failed to create object [ERROR: Don't really know what happened though !]
Can't call method "AddCounter" on an undefined value at c:/inetpub/wwwroot/cacti/scripts/mgcp.pl line 10.
crackrocksteady, do you have any insight as to why i get the following errors on your scripts? i can't figure out what it's missing.
i get similar errors for both the mgcp.pl script and the activeCalls.pl script when querying my subscriber. i've verified perfmon counters are working locally on the box and have also verified that local user account is same as cacti poller.
OK, appears to be a permissions issue, at least when I manually run it through command prompt. I still get the same errors in cacti.log when I try to let the poller run it.
My CCM boxes are not on a domain (and my Cacti box is) and after trying to run this manually from command prompt (and receiving the same error) I browsed to \\10ccm02\c$ and was immediately prompted for credentials. I supplied the login credentials for the Cacti poller job but with CCM servername in front of it (10ccm02\cacti). This is the same local account / password on both my Cacti and CCM boxes. I then re-ran the script and it ran successfully.
One question, though. Why isn't it automatically authenticating in the first place? Is there a way to modify the perl script to supply the authentication credentials when the script is executed? Or am I way off base on this one?
I can run it all day through command prompt, but it always generates the same error in cacti.log when I try to let the poller run it. I'm currently using cactid as my poller. Which poller are you using to get these to run successfully?
I should also mention that if I change my poller from cactid to cmd.php both your MGCP PRI script and your Active Calls script run fine, but your registered / unregistered phone queries break.
I know this thread is a bit dated, but thought I'd throw this out there. Anyone get this working with the Linux based CCM (version 5.x)? And if yes, can you provide some details? My Cacti install is running on a Suse Enterprise Linux Host. I'd like to query my Call Managers for PRI usage (or my Gateway routers) and graph this data over time.