Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Ciscoworks UT

Is there a way to export the hostname discovered by UT, and use it as the description field on a switch ?

3 REPLIES
Cisco Employee

Re: Ciscoworks UT

There's no way to do this automatically, but you can export the UT data to both CSV and XML. Once you have the data in such a malleable form, you could script a Netconfig job to configure the switches.

For example, you can use the "ut -cli" command to export the User Tracking data into CSV format. Parse that file to get the hostname, switch port, and switch, then use "cwcli netconfig" to deploy the commands to your switches. You can build a user-defined XML task file dynamically that holds the necessary commands. Of course, figuring out the switch type (CatOS, IOS, etc.) will be the tricky part.

If you just have IOS and CatOS switches, you can key off of the sysObjectID provided by "dcrcli exp ft=csv". sysObjectIDs that start with 1.3.6.1.4.1.9.5 are CatOS devices where as those that start with 1.3.6.1.4.1.9.1 are IOS. Once you have the OS type, you can get the MDF ID from the same dcrcli export to use in your Netconfig task file.

New Member

Re: Ciscoworks UT

I already arrived at the parse section, I have a file with hostname, switch port & switch. Can you be more specific about the "user-defined xml task" perhaps a small example ? Do I have to write xml myself ?

Many thanks

Lieven Stubbe

Belgian Railways

Cisco Employee

Re: Ciscoworks UT

Here is the example from the cwc-netconfig man page:

parameterized="false">

ip route 0.0.0.1 0.0.0.0 Ethernet0/0

ip route 0.0.0.2 0.0.0.0 Ethernet0/0

ip route 0.0.0.3 0.0.0.0 Ethernet0/0

ip route 0.0.0.4 0.0.0.0 Ethernet0/0

ip route 0.0.0.5 0.0.0.0 Ethernet0/0

ip route 0.0.0.6 0.0.0.0 Ethernet0/0

no ip route 0.0.0.4 0.0.0.0 Ethernet0/0

no ip route 0.0.0.5 0.0.0.0 Ethernet0/0

268438030,273153536,272819655

The MDF IDs can be found with a DCR export.

133
Views
0
Helpful
3
Replies
CreatePlease login to create content