cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
264
Views
0
Helpful
1
Replies

Getting Gateways,route partitions, etc from AXL

mmitchell
Beginner
Beginner

I am looking for a way to extract all of the h323/mgcp gateways, route groups, route patterns, and route lists from my 4.1 callmanager. Yet I don't see any listXXX command relevant to these items. Is there another way?

1 ACCEPTED SOLUTION

Accepted Solutions

aaronw.ca
Contributor
Contributor

We just had a bit of a discussion about using AXL vs direct database access here:

http://forum.cisco.com/eforum/servlet/NetProf?page=netprof&forum=IP%20Communications%20and%20Video&topic=IP%20Phone%20Services%20for%20Developers&CommCmd=MB%3Fcmd%3Ddisplay_location%26location%3D.1dd89d0f

Not sure if that's of any interest, but some light reading on some of the pros and cons!

There are some AXL queries that might be of use to you, such as:

listDeviceByNameAndClass

%

Gateway

where class = Gateway are gateways, though they may be FXS ports as well

Other queries you might want to check out are:

listRoutePartitionByName

or

listRoutePlanByType

Route

or

executeSQLQuery

(free-form sql query to get customized result based on the sql query you pass in...)

The devices (gateways) are the easiest to get. Take a look at the device table in CallManager's CCM03xx database (where xx is the highest-numbered database currently in the CallManager). Here's a sample SQL query:

select * from device, typeclass, typeproduct, typemodel

where device.tkclasss = typeclass.enum

and device.tkproduct = typeproduct.enum

and device.tkmodel = typemodel.enum

Devices with a tkClass of 2 are gateways, though as mentioned they may be FXS ports as well, so you may want to filter for that. See the values in the product and model fields for additional device details.

Routelist, RouteGroup, and Numplan will also be useful tables...

Just remember that when forming your own queries, if a column begins with "fk", then it links to a pkid in the table, so fkdevice links to the pkid column in the device table; and if a column begins with tk, then it links to an enum in the table (with a type prefix), so tkproduct links to the enum field in the typeproduct table.

View solution in original post

1 REPLY 1

aaronw.ca
Contributor
Contributor

We just had a bit of a discussion about using AXL vs direct database access here:

http://forum.cisco.com/eforum/servlet/NetProf?page=netprof&forum=IP%20Communications%20and%20Video&topic=IP%20Phone%20Services%20for%20Developers&CommCmd=MB%3Fcmd%3Ddisplay_location%26location%3D.1dd89d0f

Not sure if that's of any interest, but some light reading on some of the pros and cons!

There are some AXL queries that might be of use to you, such as:

listDeviceByNameAndClass

%

Gateway

where class = Gateway are gateways, though they may be FXS ports as well

Other queries you might want to check out are:

listRoutePartitionByName

or

listRoutePlanByType

Route

or

executeSQLQuery

(free-form sql query to get customized result based on the sql query you pass in...)

The devices (gateways) are the easiest to get. Take a look at the device table in CallManager's CCM03xx database (where xx is the highest-numbered database currently in the CallManager). Here's a sample SQL query:

select * from device, typeclass, typeproduct, typemodel

where device.tkclasss = typeclass.enum

and device.tkproduct = typeproduct.enum

and device.tkmodel = typemodel.enum

Devices with a tkClass of 2 are gateways, though as mentioned they may be FXS ports as well, so you may want to filter for that. See the values in the product and model fields for additional device details.

Routelist, RouteGroup, and Numplan will also be useful tables...

Just remember that when forming your own queries, if a column begins with "fk", then it links to a pkid in the table, so fkdevice links to the pkid column in the device table; and if a column begins with tk, then it links to an enum in the table (with a type prefix), so tkproduct links to the enum field in the typeproduct table.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: