cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6796
Views
0
Helpful
3
Replies
Highlighted
Beginner

How save and rollback in IOS-XR

Hello All!

Completely newbie in IOS-XR trying to get the basics using an XRv image.

I take a blank config and make some changes. I "commit label TEST"

then I do a "commit replace" to erase everything.

Then I do a "rollback configuration to TEST"

Shouldn't this lead to loading the initial changes I made in the config?

It seems not!

3 REPLIES 3
Highlighted
Cisco Employee

Hello,

 

It depends on what you see. What you should see with "rollback To" config is :

 

When you roll back the configuration to a specific rollback point, you undo all configuration changes made during the session identified by the commit ID for that rollback point, and you undo all configuration changes made after that point.

 

So if you had no config before TEST commit. Rolling back to TEST will return you to no config (moving back to the state just before TEST as per explanation).

ref:

https://www.cisco.com/c/en/us/td/docs/routers/asr9000/software/getting_started/configuration/guide/asr9k/asr9kinit.html#95487

 

HTH
Niko

HTH,
Niko
Highlighted

Thanks. So in practice i have to commit twice so that i can rollback to the second point which WIIL HAVE my changes, correct?

One more thing: My goal is to have a steady "startup-config" with basic config and do various labs. When finished and reload/stop the device, i want to have again the initial config. This is easy with IOS as we have sperate startup/running configs.

In IOS XR, what excatly is the best way to achieve that?

Highlighted

Yeah,

 

XR does not have same concept of run/start config anymore. Everything you have is committed to sysdb. So if you want to use rollback then need to keep in mind that it is doing "undo" operation upto and including the label specified.

Or alternatively you can store your "startup" to disck and copy paste it when required replacing current one:

 

copy harddisk:/test running-config replace

HTH,
Niko
Content for Community-Ad