cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
5797
Views
8
Helpful
7
Replies

SNMP: Object-ID for save the running-config?

FmSkt402
Level 1
Level 1

Hi,

I’m searching for an OID to save the running-config with a SNMP-SET-Request, equally as the ‘write’-operation in IOS.

For example that’s possible for Nortel-Passport8600-Switches:

SET 1.3.6.1.4.1.2272.1.1.8.0 (rcSysAction.0) on Value 4 = Save To NVRAM

Does anybody know if such an OID exists for Cisco-devices too?

Thank you

Rolf Fischer

7 Replies 7

gurcan_basural
Level 1
Level 1

can ı ask u a question about snmp, ı want to learn how can you apply this mib object over switch or router ,

how can you interrogate router with these objects (using program)

Unfortunately is my English far from perfection. If I understand you correctly do you want to know how you can change parameters by using SNMP.

Well, for example networkmanagement-systems like 'HP Open View' use SNMP.

Of couse you can develop your own application. That's what I'm doing (Visual Basic).

Here you can find information for developers to Windows SNMP-APIs:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/snmp/snmp/winsnmp_api.asp

Another link for code-examples:

http://www.winsnmp.com/

However I've to tell you that it took me months to understand how to create functions to send an receive SNMP-PDUs. That's the reason why I want to create a website with all that knowledge. Think that will take a couple of months likewise.

Hope, that helps you a little.

Rolf

hi,sorry ı am asking too many questions ,

you are using Hp Open View or another programs for displaying result of the snmp mib oids and you can use some mib oids to set some values for example "write to nvram" that is true

We don't use Open View but a German product called 'Realtech theGuard!':

http://www.realtech.de/international/html/framebottom.asp?substart=1822⊂=1822&pic=4&clicked=1823

SNMP allows you to read (GET) or write (SET) parameters at your device.

To do that you need the particular Object-ID inside the MIB.

For example sending an SNMP-SET-Request with the Object-ID writeMem (1.3.6.1.4.1.9.2.1.54.0) and value 1 (type Integer) saves the running-config in NVRAM (startup-config).

The value 0 erases the NVRAM.

Here a list of Cisco-Mibs:

http://www.cisco.com/univercd/cc/td/doc/product/software/ios11/mbook/mtext.htm

A IOS command to show you OIDs of your Cisco-device is:

show snmp mib

Finally a free tool to 'play' and learn about SNMP:

http://www.wtcs.org/snmp4tpc/getif.htm

For more questions please contact me directly:ro-fisch@web.de

Have fun!

Rolf

cnoctools
Level 1
Level 1

Gday Rolf,

What you're looking for used to be (not sure if it still is) in the CISCO-CONFIG-COPY mib.

The OIDs you want are:

.1.3.6.1.4.1.9.9.96.1.1.1.1.3 : ccCopySourceFileType

.1.3.6.1.4.1.9.9.96.1.1.1.1.4 : ccCopyDestFileType

.1.3.6.1.4.1.9.9.96.1.1.1.1.14 : ccCopyEntryRowStatus

.1.3.6.1.4.1.9.9.96.1.1.1.1.10 : ccCopyState

First off you need to make up some random number for your transaction, e.g. 15

The commands would be:

1. snmpset router writecomm ccCopySourceFileType.15 int 4

(This sets the source to 'runningConfig')

2. snmpset router writecomm ccCopyDestFileType.15 int 3

(This sets the dest to 'startupConfig')

3. snmpset router writecomm ccCopyEntryRowStatus.15 int 1

(This starts the transfer and sets this row in the table to read-only so you can't change your source/dest once you start.)

You can then check up on it by using:

snmpget router writecomm ccCopyState.15

HTH

Dan.

From memory the possible Source/Dest types are:

1. file on network

2. file on flash

3. startupConfig

4. runningConfig

5. terminal

and the ccCopyState values are:

1. waiting

2. running

3. success

4. failed

Hi Dan,

thank you for that: You brought me to the right way.

I found the OID 'writeMem' (1.3.6.1.4.1.9.2.1.54.0) in OLD-CISCO-SYS-MIB.

Interesting: It has WriteOnly-Access, for that reason I didn't find it in my browsefiles.

Set int 0 = Erase NVRAM-contents

Set int 1 = Copy running-config to NVRAM

Regards

Rolf

Review Cisco Networking for a $25 gift card