Monitoring Exchange 2003 from Linux Cacti

Templates, scripts for templates, scripts and requests for templates.

Moderators: Moderators, Developers

Post Reply
Author
Message
zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

Monitoring Exchange 2003 from Linux Cacti

#1 Post by zeroy » Wed Jan 25, 2006 8:34 am

Hi guys,

After spending so much time trying to get this to work I felt like sharing my solution :D . This works perfect and it is based on the XML templates from this post: http://forums.cacti.net/viewtopic.php?t ... t=exchange - Thanks to DevilSun

I re-created all the Perl scripts for use with Nagios "check_nt" and I can now Monitor the following:

Connections, Delivery stats, Filtering, IMF.[/list]

Get the XML data/graph template from the post above!
Attachments
exchange_users_script.pl.txt
(709 Bytes) Downloaded 4263 times
exchange_emails_script.pl.txt
(1.27 KiB) Downloaded 2785 times
exchange_filters_script.pl.txt
(3.8 KiB) Downloaded 2231 times
exchange_imf_script.pl.txt
(4.11 KiB) Downloaded 3428 times
¬¬ZeRoY¬¬

zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

More details

#2 Post by zeroy » Wed Jan 25, 2006 10:55 am

Forgot to add, on the exchange side, I have NSClient Distrib-1.07.1 installed as a service, SNMP + WMI installed also.

I attached the full package this time with updated XML files. Enjoy,
Attachments
exchange_cacti.zip
(25.49 KiB) Downloaded 4584 times
¬¬ZeRoY¬¬

argon0
Cacti User
Posts: 443
Joined: Fri Mar 12, 2004 1:22 pm

#3 Post by argon0 » Wed Jan 25, 2006 11:42 am

SO what do you need to do to get this to work?

Put NSClient on Exchange server? Enable SNMP? Add WMI extensions to SNMP?

Argon0
[size=50]No longer a n00by but[/size] not yet an 0ldby

Now Head of Technology at RSCH, back to the prickly subject of Monitorring....

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

#4 Post by bballard » Wed Jan 25, 2006 11:44 am

I tried to import the template and got this.
Attachments
hasherror.JPG
XML Hasherror
hasherror.JPG (25.58 KiB) Viewed 74335 times

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

Re: More details

#5 Post by bballard » Wed Jan 25, 2006 11:55 am

zeroy wrote:Forgot to add, on the exchange side, I have NSClient Distrib-1.07.1 installed as a service, SNMP + WMI installed also.
What do you use for SNMP + WMI??

zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

#6 Post by zeroy » Wed Jan 25, 2006 12:14 pm

I check templates and they import ok on my Cacti (0.8.6h) on ClarkConnect 3.2home.

What template caused the problem?

For the other question, SNMP + WMI are installed from Windows 2003 server Setup, see pic attached.
Attachments
SNMP.png
Installing SNMP + WMI on Windows 2003 Server
SNMP.png (8.96 KiB) Viewed 74320 times
¬¬ZeRoY¬¬

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

#7 Post by bballard » Wed Jan 25, 2006 12:25 pm

I am using Cacti 0.6.8g, I wonder if thats my problem....

zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

#8 Post by zeroy » Wed Jan 25, 2006 12:45 pm

Couldn't tell, my first time using Cacti :D
¬¬ZeRoY¬¬

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

#9 Post by bballard » Wed Jan 25, 2006 2:31 pm

Yeah that is it. Since your using a higher version cacti the XML hash is too high. I am reviewing this post to see if I can use the new XML somehow.

http://forums.cacti.net/viewtopic.php?t ... r+xml+hash

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

#10 Post by bballard » Wed Jan 25, 2006 2:54 pm

I see nothing that can help me. I guess I have to upgrade to 0.6.8h. Can anyone think of anything else before I upgrade. I would hate to upgrade a good stable Cacti installation.

zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

#11 Post by zeroy » Wed Jan 25, 2006 4:32 pm

My XML templates are taken from these:
http://forums.cacti.net/viewtopic.php?t ... t=exchange

See if you can import those, if yes then all you have to change is the "Data Input Method". In there change the name of the Perl Script you are calling + remove the <instance> input field and also the <instance> after the Perl script path.
¬¬ZeRoY¬¬

bballard
Posts: 35
Joined: Thu Jan 19, 2006 11:58 am

#12 Post by bballard » Wed Jan 25, 2006 5:24 pm

I will give that a try tonight and let you know the results. Maybe that will help other struggling Unix admins.. :lol:

argon0
Cacti User
Posts: 443
Joined: Fri Mar 12, 2004 1:22 pm

#13 Post by argon0 » Thu Jan 26, 2006 4:47 am

Zeroy:

I've installed WMI + SNMP on win2k - is any further configuration required once installed?

<cheers>

Argon0
[size=50]No longer a n00by but[/size] not yet an 0ldby

Now Head of Technology at RSCH, back to the prickly subject of Monitorring....

argon0
Cacti User
Posts: 443
Joined: Fri Mar 12, 2004 1:22 pm

#14 Post by argon0 » Thu Jan 26, 2006 6:29 am

Ok... Got the templates imported/installed - but graphs are all blank,.,.

Debugging the graphs gives (for instance):

Code: Select all

 	 RRDTool Command:

/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="CRYUKE16EX1 - Exchange Connections" \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="Connections" \
--slope-mode \
DEF:a="/var/www/html/rra/cryuke16ex1_count_active_users_164.rrd":count_users:AVERAGE \
DEF:b="/var/www/html/rra/cryuke16ex1_count_active_users_164.rrd":count_active_users:AVERAGE \
AREA:a#005199:"Users"  \
GPRINT:a:LAST:"       Current\:%8.0lf"  \
GPRINT:a:AVERAGE:"Average\:%8.0lf"  \
GPRINT:a:MAX:"Maximum\:%8.0lf\n"  \
LINE2:b#FF4105:"Active Users"  \
GPRINT:b:LAST:"Current\:%8.0lf"  \
GPRINT:b:AVERAGE:"Average\:%8.0lf"  \
GPRINT:b:MAX:"Maximum\:%8.0lf\n" 

RRDTool Says:

OK
Is there anything else I need to start on the Exchange server?[/code]
[size=50]No longer a n00by but[/size] not yet an 0ldby

Now Head of Technology at RSCH, back to the prickly subject of Monitorring....

zeroy
Posts: 25
Joined: Wed Jan 25, 2006 8:27 am

#15 Post by zeroy » Thu Jan 26, 2006 7:43 am

Can you get SNMP infos from your Win2k host? if so then it should work ok. Make sure NSClient is running as well on the W2k host. Also Nagios check_nt needs to be installed on the Cacti box,
¬¬ZeRoY¬¬

Post Reply