91
Views
0
Helpful
0
Comments

Options
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
on 01-24-2014 02:14 PM
This document was generated from CDN thread
Created by: Chester Rieman on 09-05-2011 06:49:54 AM
IT took s bit of hammring at it but I finally got this.
You need to send this XML:
<?xml version="1.0" encoding="utf-8" ?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soapenv:Body>
<nsl
erfmonCollectCounterData
soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:nsl="http://schemas.cisco.com/ast/soap/">
<Host xsi:type="xsd:string">x.x.x.x</Host>
<Object xsi:type="nsl
bjectNameType">Number of Replicates Created and State of Replication</Object>
</nsl
erfmonCollectCounterData>
</soapenv:Body>
</soapenv:Envelope>
I use curl to send this to CUCM - seems to be the simplest way from a *nix machine.
curl -s -k -u username:password -H 'Content-type: text/xml;' -H 'SOAPAction: "CUCM
B ver=6.0"' -d @filename.xml https://x.x.x.x:/perfmonservice/services/PerfmonPort > resultfile.txt
So here we are pulling system perfmon object for "Number of Replicates Created and State of Replication" by querying perfmonservice/services/PerfmonPort
http://www.cisco.com/en/US/docs/voice_ip_comm/cucm/service/8_5_1/rtmt/rtpmsys.html#wp1058441
once run you can take resultfile.txt and extract the replicate_state value:
awk -F '>' '/Replicate_State/ { print "Replicate_State of SERVERNAME " $18> "outfile.txt"}' resultfile.txt
resultfile.txt contains the xml response from cucm
outfile.txt will look like:
Replicate_State of SERVERNAME 2
You can string these together to create an output file with replication state for each server in the cluster and make the whole thing a cron job - I use CLI mutt to send myself a daily email with replication state for the cluster.
You can use similar methods for any system or CUCM perfmon objects.
Created by: Chester Rieman on 09-05-2011 06:49:54 AM
IT took s bit of hammring at it but I finally got this.
You need to send this XML:
<?xml version="1.0" encoding="utf-8" ?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soapenv:Body>
<nsl

soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:nsl="http://schemas.cisco.com/ast/soap/">
<Host xsi:type="xsd:string">x.x.x.x</Host>
<Object xsi:type="nsl

</nsl

</soapenv:Body>
</soapenv:Envelope>
I use curl to send this to CUCM - seems to be the simplest way from a *nix machine.
curl -s -k -u username:password -H 'Content-type: text/xml;' -H 'SOAPAction: "CUCM

So here we are pulling system perfmon object for "Number of Replicates Created and State of Replication" by querying perfmonservice/services/PerfmonPort
http://www.cisco.com/en/US/docs/voice_ip_comm/cucm/service/8_5_1/rtmt/rtpmsys.html#wp1058441
once run you can take resultfile.txt and extract the replicate_state value:
awk -F '>' '/Replicate_State/ { print "Replicate_State of SERVERNAME " $18> "outfile.txt"}' resultfile.txt
resultfile.txt contains the xml response from cucm
outfile.txt will look like:
Replicate_State of SERVERNAME 2
You can string these together to create an output file with replication state for each server in the cluster and make the whole thing a cron job - I use CLI mutt to send myself a daily email with replication state for the cluster.
You can use similar methods for any system or CUCM perfmon objects.
Labels: