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

Restore vlan.dat file on switches

Running RME 4.0.3, the config files and the vlan info are stored in 2 seperate files. If ,for example, a C2950 switch dies, it needs to be replaced by a new one. The actual config is no problem, but how do you restore the vlan.dat file ?

I already tried to copy the cfg file from the shadow dir into the new switch using tftp, but the actual vlan.dat and the cfg file in the VLAN dir are not the same !! Are there other places where the vlan.dat info is stored without modification ?

In addition, what if you have a switch wich is server in a vtp domain, and loses it's vlan info, you have the same problem, how do you restore the vlan.dat ?? Many thanks in advance.

Lieven Stubbe

Belgian Railways

17 REPLIES
Cisco Employee

Re: Restore vlan.dat file on switches

Answered in earlier post for you:

The vlan.dat files are not copied into the shadow directory. They are binary files which are unreadable by humans.

But in the file system (\CSCOpx\files\archive\config) you would

see something like this:

20051028161009running.cfg

20051028161009vlan.cfg

20051028161707running.cfg

20051028161707vlan.cfg

If you have five generations of running configs archived, the version numbers for running

and vlan.dat will be matched. So if you want to restore version 4 of the running config,

you would restore version 4 of the vlan config.

You need to use the CLI to restore the vlan and here is the command:

cwconfig put -u username -p password -device device_name ?version version_number -filetype vlan

You have to reboot the device after downloading the VLAN configuration. Only after you reboot the device, will the VLAN configuration take effect.

New Member

Re: Restore vlan.dat file on switches

I don't understand anymore, beneath the /var/adm/CSCOpx/files/rme/dcma/shadow/Switches & Hubs

directory I have a PRIMARY dir(wich contains the config) and a VLAN dir (I suppose the vlan.dat info ?)

Files like 20051028161009running.cfg are not on my system, anyway the the archive setting is set to : /var/adm/CSCOpx/files/rme/dcma, and in the /archive/config dir I find nothing.

What am I doing wrong ?? I need to find a way to restore my vlan.dat, is this a serious lag in CW ?

Many thanks

Cisco Employee

Re: Restore vlan.dat file on switches

You can get the version # of the vlan.dat you are looking to restore from the version summary tree

in the GUI. Also, refer to this link:

http://www.cisco.com/univercd/cc/td/doc/product/rtrmgmt/cw2000/cw2000e/e_4_x/4_0_3/u_guide/cwcli.htm#wp1078088

Then once you determine the version # you can use the following command:

/opt/CSCOpx/bin/cwcli config put -u -p -device -filetype vlan -version

New Member

Re: Restore vlan.dat file on switches

What's the big deal about the vlan.dat file? Add the switch to the vtp domain and let the vlans replicate from the other switches. What am I missing?

Unless it's the only vtp server switch and it went down. Then the vlan information went with it.

New Member

Re: Restore vlan.dat file on switches

Thanks to all for your responses, if the switch is a client in the VTP domain, there is indeed no problem, but if the switch is server and loses it's vlan database, is there a way to restore this using CW ?

Cisco Employee

Re: Restore vlan.dat file on switches

You can restore it using the above steps and CLI command

New Member

Re: Restore vlan.dat file on switches

I am aware of the cwcli config put command, but if you lose a switch who is server in a VTP domain, this switch becomes unreachable, how do you resolve this problem ? We already had this problem, the only way to resolve is to connect via a console cable and manually enter all the vlans into the switch !!

Cisco Employee

Re: Restore vlan.dat file on switches

If the switch becomes unreacable then there's nothing that CiscoWorks can do. You would need to connect via console and enter the basic info (IP addr, snmp comm strings) and then you can use the cwcli commands.

New Member

Re: Restore vlan.dat file on switches

I have forseen this problem, you've experienced it! It's like putting all your eggs in one basket.

Why not create another VTP server? This will act like a back-up VTP server. No?

New Member

Re: Restore vlan.dat file on switches

I tried to restore a vlan.dat using the cwcli commando on a switch in our testenvironment.

hstest01

INFO - CM0103 Put the config file to VLAN Running Config on device successful

CM0089 Config archival successful for hstest01

INFO - The transport mode used is Telnet

SUMMARY

========

Successful: put

Everything seems to have worked fine, until I do a reload, then I get the following message in the log : %SW_VLAN-4-BAD_VLAN_CONFIGURATION_FILE: VLAN configuration file contai

ned incorrect verification word: 0xBADB100A

What am I doing wrong ?

Silver

Re: Restore vlan.dat file on switches

Does the "new switch" run the same software as the "old" one? I'm tolled this won't work if the IOS in not the same on both machine.

Cheers,

Michel

New Member

Re: Restore vlan.dat file on switches

I set up a test env where I could test the working of cwcli get/put utility. The get works fine and saves the config and vlan data to disk. Things go wrong after the use of the put command, the vlan.dat is pushed back to the device, but it gives this error after reload: SW_VLAN-4-BAD_VLAN_CONFIGURATION_FILE: VLAN configuration file contai

ned incorrect verification word: 0xBADB100A

The vlan.dat has 1 byte more than before the put/get operation. It is not the same file anymore. What went wrong ? There is a serious problem in doing the put of the vlan data file.

New Member

Re: Restore vlan.dat file on switches

I set up a test env where I could test the working of cwcli get/put utility. The get works fine and saves the config and vlan data to disk. Things go wrong after the use of the put command, the vlan.dat is pushed back to the device, but it gives this error after reload: SW_VLAN-4-BAD_VLAN_CONFIGURATION_FILE: VLAN configuration file contai

ned incorrect verification word: 0xBADB100A

The vlan.dat has 1 byte more than before the put/get operation. It is not the same file anymore. What went wrong ? There is a serious problem in doing the put of the vlan data file.

New Member

Re: Restore vlan.dat file on switches

I set up a test env where I could test the working of cwcli get/put utility. The get works fine and saves the config and vlan data to disk. Things go wrong after the use of the put command, the vlan.dat is pushed back to the device, but it gives this error after reload: SW_VLAN-4-BAD_VLAN_CONFIGURATION_FILE: VLAN configuration file contai

ned incorrect verification word: 0xBADB100A

The vlan.dat has 1 byte more than before the put/get operation. It is not the same file anymore. What went wrong ? There is a serious problem in doing the put of the vlan data file.

Silver

Re: Restore vlan.dat file on switches

Why don't cut-paste all in and output?

Also rather then using cwcli try using a (any) tftpserver to do this.

Push and pull the vlan.dat to a tftpserver and see if this gives the same issue.

I recommend tftpd32 (just google it) because you can put the security to "none" (for the test) and then you can upload any file without creating it.

Cheers,

Michel

New Member

Re: Restore vlan.dat file on switches

Thanx for the answer, but the problem remains, if I do a cut/paste using tftp (like we did before) everything is fine, but we have 2600 devices, so doing it manually is virtually impossible ;-))

with cwcli, when doing a get/put on a test device, everything ends succesfull, but after reload the message mensioned above is logged.

cw alters the vlan.dat and writes the altered version back to the switch, is this normal ?

Silver

Re: Restore vlan.dat file on switches

This is not normal. Do make sure you have the latest device packages for the devices involved.

If you have established that there is a difference between copying the vlan.dat to and from a particular device using tftp and using cwcli then you best open a ticket with cisco TAC to get a fix.

Cheers,

Michel

2105
Views
9
Helpful
17
Replies
CreatePlease login to create content