SNMP configuration backup

Answered Question
Sep 24th, 2011

I am doing daily backup on our IOS platforms with command:

snmpset -r 3 -t 30 -v2c -c COMM HOST .1.3.6.1.4.1.9.2.1.55.XXX.XXX.XXX.XXX s HOST-confg

There is no mib for this in IOS XR.

Is there any other solution for automatic config backup ?

I have this problem too.
0 votes
Correct Answer by Alexei Kiritchenko about 3 years 8 months ago

Hello Dragoljub,

XR supports  CISCO-CONFIG-COPY-MIB instead to copy config files.

Here is an example. (777 is a random session number)

Create an Entry and Wait

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 5

Set Copy protocol to tftp

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.2.777 i 1

Set copy to tftp server

              snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.3.777 i 4

Set copy from config     

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.4.777 i 1

Set tftp server address

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.5.777 a 1.1.1.1

Set destination file name

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.6.777 s runningTest.txt

Activate the entry          

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 1

Verify the copy was successful

                snmpwalk -v2c -c COMMUNITY HOST ccCopyState

Once successful, destroy the entry

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 6

Regards,

/A

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (3 ratings)
Vadim Zhovtanyuk Sat, 09/24/2011 - 04:42

Hi Dragoljub,

you may use EEM script to run daily operations.

http://www.cisco.com/en/US/docs/routers/crs/software/crs_r4.1/system_monitoring/configuration/guide/sysmon_cg41crs_chapter2.html

Other solutoin may be script running on PC wich will be connecting to XR-based devices and run the commands

BWR

V.

Correct Answer
Alexei Kiritchenko Sat, 09/24/2011 - 13:10

Hello Dragoljub,

XR supports  CISCO-CONFIG-COPY-MIB instead to copy config files.

Here is an example. (777 is a random session number)

Create an Entry and Wait

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 5

Set Copy protocol to tftp

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.2.777 i 1

Set copy to tftp server

              snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.3.777 i 4

Set copy from config     

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.4.777 i 1

Set tftp server address

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.5.777 a 1.1.1.1

Set destination file name

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.6.777 s runningTest.txt

Activate the entry          

                snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 1

Verify the copy was successful

                snmpwalk -v2c -c COMMUNITY HOST ccCopyState

Once successful, destroy the entry

               snmpset -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.14.777 i 6

Regards,

/A

Dragoljub Spasojevic Sun, 09/25/2011 - 02:51

I just want to add that i have problems with "Verify step".

So just use OID ...

snmpwalk -v2c -c COMMUNITY HOST .1.3.6.1.4.1.9.9.96.1.1.1.1.10

Actions

Login or Register to take actions

This Discussion

Posted September 24, 2011 at 4:34 AM
Stats:
Replies:3 Overall Rating:5
Views:3139 Votes:0
Shares:0
Tags: No tags.