cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Highlighted
Level 16

Device template not for backup configuration..

Hi

Its probably a feature request ...

Is there a way to get a device template that gets other information from the device?

like in case of HW that has not a inventory MIB for example?

or just like to enrich the the backup file with more details?

/sja

Labels (1)
Tags (1)
0 Kudos
10 Replies
Highlighted

Re: Device template not for backup configuration..

sja​ You can definitely create your own, and have the system work for you. For example, I have been able to get NCM to actually backup my .bash* files on my Linux servers. I just have it cat a file, and it dumps it right into the new config type to be downloaded. I have also added a few lines to a couple of other device templates, and created new download types for DHCP, software versions, etc.. Now I am able to backup output from device commands, just the same as a regular backup. I download the basic running & startup configs, as well as a custom DHCP, software version, and a few other minor things. NCM keeps them all in history, and I can now track things, otherwise hidden from view. You just have to build out your commands properly in the device template, and then NCM will do exactly what you have told it to do.

0 Kudos
Highlighted
Level 16

Re: Device template not for backup configuration..

Hi wluther

I like to get some chassis information with a backup file or just other file I just like that to be in the DB ...

If I have a standard juniper ou of the box template ...

can I just add extra command line ?

<Configuration-Management Device="Juniper Display set" SystemOID=" 1.3.6.1.4.1.2636">

  <Commands>

    <Command Name="Reset" Value="set cli complete-on-space off${CRLF}set cli screen-width 0${CRLF}set cli screen-length 0" />

    <Command Name="Reboot" Value="request system reboot${CRLF}yes" />

    <Command Name="EnterConfigMode" Value="configure" />

    <Command Name="ExitConfigMode" Value="commit and-quit" />

    <Command Name="DownloadConfig" Value="show configuration | display set" />

    <Command Name="UploadConfig" Value="${EnterConfigMode}${CRLF}${ConfigText}${CRLF}${ExitConfigMode}" />

    <Command Name="SaveConfig" Value="${EnterConfigMode}${CRLF}${ExitConfigMode}" />

    <Command Name="Version" Value="show version brief" />

    <Command Name="Running" Value="" />

    <Command Name="Startup" Value="" />

  </Command Name="My extra commando"/>

</Configuration-Management>

0 Kudos
Highlighted

Re: Device template not for backup configuration..

sja​ Yeah, pretty much. For mine, I copied the "running" line of the template, pasted it below the line, and altered it. I had to change the name, so I set it to "DHCP". Then, in the NCM settings, I created a new type of config, calling it the same name as the line I added, "DHCP". Originally, before I made any changes, I only had the two standard options, "Running", and "Startup". Now, I have those two options, as well as my "DHCP" option. Whenever I select it, and run it, it goes out, based on that new line of the template, and runs that new command. Basically, any command that shows you output, can easily be put into a new config type, and captured by NCM. I have not really modified other aspects of the template, as I have been able to accomplish my goals with this minor process.

0 Kudos
Highlighted
Level 16

Re: Device template not for backup configuration..

Hi

I like that Template to run the "show log inventory"

Its work if I change the startup to "show log inventory

do I need to make new type configuration  named  "inventory"?

/Sja

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

<!-- edited with XML Spy v4.4 U (http://www.xmlspy.com) by () -->

<!--SolarWinds Network Management Tools-->

<!--Copyright 2005 SolarWinds.Net All rights reserved-->

<Configuration-Management Device="Juniper Devices" SystemOID=" 1.3.6.1.4.1.2636">

  <Commands>

  <Command Name="Reset" Value="set cli complete-on-space off${CRLF}set cli screen-width 0${CRLF}set cli screen-length 0"/>

  <Command Name="Reboot" Value="request system reboot${CRLF}yes"/>

  <Command Name="EnterConfigMode" Value="configure"/>

  <Command Name="ExitConfigMode" Value="commit and-quit"/>

  <Command Name="DownloadConfig" Value="Show configuration"/>

  <Command Name="UploadConfig" Value="${EnterConfigMode}${CRLF}${ConfigText}${CRLF}${ExitConfigMode}"/>

  <Command Name="SaveConfig" Value="${EnterConfigMode}${CRLF}${ExitConfigMode}"/>

  <Command Name="Version" Value="show version brief"/>

                <Command Name="Juniper Inventory" Value="show log inventory"/>

                </Commands>

               </Configuration-Management>

0 Kudos
Highlighted

Re: Device template not for backup configuration..

sja

Maybe try using variable name without spaces?

<Command Name="Juniper Inventory" Value="show log inventory"/>

<Command Name="JuniperInventory" Value="show log inventory"/>

I'll check my templates when I get back in the office next week, and then I'll let you know how they are setup.

0 Kudos
Highlighted
Level 16

Re: Device template not for backup configuration..

Hej

That drive med nuts..

It's not working I probebly need some other eyes in that.

/SJA

<!-- edited with XML Spy v4.4 U (http://www.xmlspy.com) by () -->

<!--SolarWinds Network Management Tools-->

<!--Copyright 2005 SolarWinds.Net All rights reserved-->

<Configuration-Management Device="Juniper Devices" SystemOID=" 1.3.6.1.4.1.2636">

  <Commands>

  <Command Name="Reset" Value="set cli complete-on-space off${CRLF}set cli screen-width 0${CRLF}set cli screen-length 0"/>

  <Command Name="Reboot" Value="request system reboot${CRLF}yes"/>

  <Command Name="Show_log_inventory" Value="show log inventory"/>

  <Command Name="EnterConfigMode" Value="configure"/>

  <Command Name="ExitConfigMode" Value="commit and-quit"/>

  <Command Name="DownloadConfig" Value="show configuration | display set"/>

  <Command Name="UploadConfig" Value="${EnterConfigMode}${CRLF}${ConfigText}${CRLF}${ExitConfigMode}"/>

  <Command Name="SaveConfig" Value="${EnterConfigMode}${CRLF}${ExitConfigMode}"/>

  <Command Name="Version" Value="show version brief"/>

  </Commands>

</Configuration-Management>

0 Kudos
Highlighted

Re: Device template not for backup configuration..

sja​ Are you making the changes in BOTH locations? (Device Template & NCM Config Settings)

After you add the config type in the device template, you need to make sure to add that same config type to the NCM Config Settings page.

Try this, just to keep it simple, and not use spaces or underscores, for now...

<Command Name="ShowLogInventory" Value="show log inventory"/>

Then add the same config type, as shown below.

NCM_Config_Settings_20170606_0729.png

Or, are you having some other issue(s)? Have you already done the steps above, but are having a different issue?

Thank you,

-Will

0 Kudos
Highlighted
Level 16

Re: Device template not for backup configuration..

Yes I think I do

I try to clean up and try with other command

When I push download "ShowChassisHardware" I get the "DownloadConfig" ...

<!-- edited with XML Spy v4.4 U (http://www.xmlspy.com) by () -->

<!--SolarWinds Network Management Tools-->

<!--Copyright 2005 SolarWinds.Net All rights reserved-->

<Configuration-Management Device="Juniper Devices" SystemOID=" 1.3.6.1.4.1.2636">

  <Commands>

  <Command Name="Reset" Value="set cli complete-on-space off${CRLF}set cli screen-width 0${CRLF}set cli screen-length 0"/>

  <Command Name="Reboot" Value="request system reboot${CRLF}yes"/>

  <Command Name="EnterConfigMode" Value="configure"/>

  <Command Name="ExitConfigMode" Value="commit and-quit"/>

  <Command Name="DownloadConfig" Value="show configuration"/>

  <Command Name="UploadConfig" Value="${EnterConfigMode}${CRLF}${ConfigText}${CRLF}${ExitConfigMode}"/>

  <Command Name="SaveConfig" Value="${EnterConfigMode}${CRLF}${ExitConfigMode}"/>

  <Command Name="Version" Value="show version brief"/>

                 <Command Name="ShowChassisHardware" Value="show chassis hardware"/>

  </Commands>

</Configuration-Management>

pastedImage_0.png

pastedImage_1.png

0 Kudos
Highlighted

Re: Device template not for backup configuration..

sja​ That seems odd. So, you are saying once you click on that "06-06-2017 15:11 - ShowChassisHardware" link, it takes you in to view the config, but the results are showing as if the command ran one of the default config backups, or does it show you the data you would expect to see?

If I had to guess, from what you have shown above, I would say everything appears to be working as it should. However, that all depends on the contents of that "ShowChassisHardware" config that has been downloaded.

0 Kudos