The imported template for netscaler doesn't work well

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
guanxi555
Posts: 8
Joined: Fri Jun 05, 2009 10:54 pm

The imported template for netscaler doesn't work well

Post by guanxi555 »

Hi, my friends,

I got a graphing issue with an imported template for Citrix Netscaler. This template is supposed to help me collect the statistics of the client connections to our websites so that I can monitor how many external users are accessing each of our websites in the real time. It's very important for our website management.

I got this template in Cacti Forum and imported it properly, however after I successfully created a new device in cacti and begin to create detailed graph about the virtual servers for this netscaler device, the problem occured after the Cacti walked through the SNMP OID tree according to the SNMP OID table in the Vserver XML file.

Firstly, I couldn't see all the corresponding graph options for all our configured virtual servers in the real appliance.

Secondly, after I created a few of the graphs for the virtual servers listed in the cacti, the graph data collected by Netscaler is "Nan".
Attachments
Creating graphs for Netscaler Vserver table .jpg
Creating graphs for Netscaler Vserver table .jpg (71.24 KiB) Viewed 4694 times
Vserver Graphing issue without data showing up.jpg
Vserver Graphing issue without data showing up.jpg (109 KiB) Viewed 4694 times
ns_servicetable.xml
(2.84 KiB) Downloaded 162 times
cacti_graph_template_netscaler_-_vsvr_-_traffic.xml
(17.53 KiB) Downloaded 172 times
cacti_graph_template_netscaler_-_vsvr_-_requestsresponses.xml
(15.93 KiB) Downloaded 157 times
guanxi555
Posts: 8
Joined: Fri Jun 05, 2009 10:54 pm

follow the last post

Post by guanxi555 »

Please take a look at the following snapshots.

The debug output looks good, but nothing show up in the graph view.

Could anyone please give me some help or suggestion? I have been stuck here for several days.

Thanks a lot!
Attachments
cacti_graph_template_netscaler_-_vsvr_-_connections.xml
(15.91 KiB) Downloaded 142 times
Debug output of one of the graphs.jpg
Debug output of one of the graphs.jpg (143.46 KiB) Viewed 4691 times
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

You should be posting your problems in the thread where you got the template from. Also read http://docs.cacti.net/manual:087:4_help.2_debugging
guanxi555
Posts: 8
Joined: Fri Jun 05, 2009 10:54 pm

Further investigation result of this graphing issue

Post by guanxi555 »

Hi, man,

Thanks for your suggestion, however I am sorry the templates for Citrix Netscaler I am using is a new template my friend gave me. So I didn't post my comment following the other thread with a similar topic. My templates for Citrix Netscaler work much better for me than the one which was posted before on the forum.

I have attached this set of templates and would like to share it with all the friends here. Actually I have been very close to the final success of graphing the Citrix Netscaler so far. The graphs for the CPU utilization, Vserver Total Client Connections.. etc work very well.

And I followed your troubleshooting instruction and have figured out why it was always unable to get the correct snmp query result and gave me an error message in the log as following,

"07/24/2009 02:00:03 PM - CMDPHP: Poller[0] Host[21] DS[118] WARNING: Result from SNMP not valid. Partial Result: U "

The reason is when I created the new host for this Netscaler device, it run a data query and snmpwalked the OID tree as the XML template instructed. But it automatically generate a new wrong OID for each of child object under the OID subtree which corresponds to a specific WEB load-balancing service. Please take a look at the verbose result of the CACTI snmpwalk.

***********************************************
Data Query Debug Information
+ Running data query [13].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/var/www/html/cacti/resource/snmp_queries/netscaler_v8_1_vserver_statistics.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.5951.4.1.3.1.1.1'
+ Index found at OID: '1.3.6.1.4.1.5951.4.1.3.1.1.1.23.115.115.108.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109' value: 'ssl-vsrv-www.canbet.com'
+ Index found at OID:
... (omitted)

+ index_parse at OID: '1.3.6.1.4.1.5951.4.1.3.1.1.1.23.115.115.108.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109' results: '3.115.115.108.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109'

***************************************************************
Please notice that the snmp OID in the last line of the data-query output is not existed. If the CACTI was able to resolve the child OID to .23.115.115.108.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109 , it would be able to get the correct the snmp-query result from the appliance. The tiny difference is the first number in the OID string, the number in the wrong one is "3", and the one in the correct snmp OID is "23". But if I just make a snmpwalk for the OID 1.3.6.1.4.1.5951.4.1.3.1.1.1, I can get all the correct sub-OIDs and results successfully as following

*******************************************************
[root@promellnnet01 snmp_queries]# snmpwalk -Os -c c0ntr0l -v1 10.4.100.1 1.3.6.1.4.1.5951.4.1.3.1.1.7

[root@promellnnet01 snmp_queries]# snmpwalk -Os -c c0ntr0l -v1 10.4.100.1 1.3.6.1.4.1.5951.4.1.3.1.1.7
enterprises.5951.4.1.3.1.1.7.23.115.115.108.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.23.115.115.108.45.118.115.114.118.45.119.119.119.46.99.98.101.116.56.56.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.23.118.115.114.118.45.105.110.116.101.114.110.97.108.45.68.78.83.45.112.114.111.120.121 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.24.73.110.116.114.97.45.67.97.110.98.101.116.45.67.77.84.45.83.101.114.118.105.99.101 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.24.104.116.116.112.45.118.115.114.118.45.109.117.112.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.24.104.116.116.112.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 337
enterprises.5951.4.1.3.1.1.7.24.104.116.116.112.45.118.115.114.118.45.119.119.119.46.99.98.101.116.56.56.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.25.104.116.116.112.45.118.115.114.118.45.73.65.83.66.69.84.45.82.101.100.105.114.101.99.116 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.25.115.115.108.45.118.115.114.118.45.112.111.107.101.114.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.26.104.116.116.112.45.118.115.114.118.45.102.101.101.100.115.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 16
enterprises.5951.4.1.3.1.1.7.26.104.116.116.112.45.118.115.114.118.45.112.111.107.101.114.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.26.104.116.116.112.45.118.115.114.118.45.119.119.119.46.99.97.110.98.101.116.46.99.111.46.117.107 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.27.104.116.116.112.45.118.115.114.118.45.99.97.115.105.110.111.46.99.97.110.98.101.116.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.27.115.115.108.45.118.115.114.118.45.119.119.119.46.103.97.116.101.119.97.121.51.54.56.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.28.73.110.116.114.97.45.67.97.110.98.101.116.45.66.97.110.107.105.110.103.45.83.101.114.118.105.99.101 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.28.104.116.116.112.45.118.115.114.118.45.119.119.119.46.103.97.116.101.119.97.121.51.54.56.46.99.111.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.31.73.78.49.116.120.116.109.53.97.109.50.99.102.100.98.100.118.49.101.115.52.98.98.101.110.49.108.108.117.100.114 = Gauge32: 4
enterprises.5951.4.1.3.1.1.7.31.73.78.50.103.121.51.108.120.97.103.101.120.50.119.104.99.52.105.52.110.110.119.100.99.113.97.103.104.53.99.114 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.31.73.78.104.120.99.111.109.97.97.110.53.52.98.98.113.99.108.53.114.117.118.121.98.105.112.100.115.49.49.100.49 = Gauge32: 152
enterprises.5951.4.1.3.1.1.7.31.73.78.117.101.104.99.98.53.99.51.51.50.100.101.102.99.107.106.104.122.52.99.98.51.48.50.101.108.49.99.109 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.31.73.78.120.118.97.98.106.111.98.109.112.108.112.104.101.100.119.51.115.102.115.122.99.109.105.97.117.118.111.98.121 = Gauge32: 0
enterprises.5951.4.1.3.1.1.7.31.73.110.116.114.97.45.67.97.110.98.101.116.45.66.101.116.77.97.110.97.103.101.114.45.83.101.114.118.105.99.101 = Gauge32: 0

*****************************************************

Now I know where the problem is, but don't know where and how it came out. I guess I might have to tweak somewhere in the template. Could anyone give me some suggestion and help me out?

Many thanks.



Ray Guan
Attachments
ns81_cacti_template.zip
(17.44 KiB) Downloaded 135 times
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

The wrong OID index being parsed on that particular example is likely due to the wrong REGEX. In netscaler_v8_1_vserver_statistics.xml, try changing it to<oid_index_parse>OID/REGEXP:^.{29}(.*)</oid_index_parse>. Basically this regex is taking the first 29 characters and splitting off anything after that. If the fixed length doesn't work, you'll need to change the REGEX so it can compensate for variable length OIDs...
guanxi555
Posts: 8
Joined: Fri Jun 05, 2009 10:54 pm

The graghing issue is fixed!!! awesome

Post by guanxi555 »

Hi, man,

thank a lot for your suggestion. It works now after I follow your instruction modifying the REGEX value. It works very well. Now I think this template is completely working for netscaler9.0. I also attahed my revised templates again. Hope it could help others who need this set of templates for citrix netscaler.

Thanks again. Now I have learned more useful knowledge and got clearer about how CACTI works.

Cheers

Ray
Attachments
ns90_cacti_template.rar
(14.72 KiB) Downloaded 281 times
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Would it be an option to publish this template at the template repository? Please see 4th link of my sig
Reinhard
vrturbo
Posts: 9
Joined: Thu Apr 22, 2010 8:24 pm

Post by vrturbo »

Hi All,

I'm trying to use this template, everything seems to be working except the interface traffic and packets. I can see from my poller log I have a double dot ".." being set somewhere, see below:

<interface>
<name>Get SNMP NetScaler Interfaces</name>
<description>Queries a NetScaler 9.0 for a list of monitorable interfaces</description>
<oid_index>.1.3.6.1.4.1.5951.4.1.1.54.1.1</oid_index>
<oid_index_parse>OID/REGEXP:^.{29}(.*)</oid_index_parse>

<fields>
<ifName>
<name>Interface Name</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.5951.4.1.1.54.1.1</oid>
</ifName>
<ifRxBytes>
<name>Number of bytes received by this interface</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.5951.4.1.1.54.1.3</oid>
</ifRxBytes>
<ifTxBytes>
<name>Number of bytes transmitted by this interface</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.5951.4.1.1.54.1.7</oid>
</ifTxBytes>
<ifRxPkts>
<name>Number of packets received by this interface</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.5951.4.1.1.54.1.5</oid>
</ifRxPkts>
<ifTxPkts>
<name>Number of packets transmitted by this interface</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.5951.4.1.1.54.1.9</oid>
</ifTxPkts>
</fields>
</interface>


and the poller cache log

KogCAG01 - NetScaler v9.0 Interface Traffic SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.7..3.49.47.54
RRD: /var/www/cacti/rra/kogcag01_ns_traffic_in_138.rrd
KogCAG01 - NetScaler v9.0 Interface Traffic SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.3..4.76.65.47.49
RRD: /var/www/cacti/rra/kogcag01_ns_traffic_in_139.rrd
KogCAG01 - NetScaler v9.0 Interface Traffic SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.7..4.76.65.47.49
RRD: /var/www/cacti/rra/kogcag01_ns_traffic_in_139.rrd
KogCAG01 - NetScaler v9.0 Packets SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.5..3.49.47.51
RRD: /var/www/cacti/rra/kogcag01_ns_packets_out_132.rrd
KogCAG01 - NetScaler v9.0 Packets SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.9..3.49.47.51
RRD: /var/www/cacti/rra/kogcag01_ns_packets_out_132.rrd
KogCAG01 - NetScaler v9.0 Packets SNMP Version: 2, Community: Pathf1nd3r, OID: .1.3.6.1.4.1.5951.4.1.1.54.1.5..3.49.47.52
RRD: /var/www/cacti/rra/kogcag01_ns_packets_out_133.rrd

Thanks in advance for your help
Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests