In IOS XR when you are configuring something you need to commit it, so it is in runing config. The configuration is saved to candidate config before committing. You show the candidate config via command „show config“. When you commit the config thats gonna be merged with the running config.

When you execute „show config merge“ you see what is the running config, what is the candidate config and what will be the result of committing the config – how it will merge. Also when you do the commit all the changes are saved and their ID can be listed. So every change is stored and you dont lost it! Try with „show config rollback change“. So if you need to undo some change this feature allows it. So if you need to rollback some change you can do it via „rollback config last 1“. The number 1 is always your last change. So for example if you execute with number 2 it will rollback the 2 changes, including the second change and create new change so you can rollback that also. You can also list what happen if you rollback the config via command „show config rollback changes last 3“ This shows you what happen if you rollback the last 3rd config changes, including the number 3. You can also see what happens if you rollback TO something via command „show config rollback changes to 3“ It shows you whole rollback all the way to the last 3rd change. When you then indeed rollback the change for example via „rollback config to 3“ it will rollback the changes to the last 3rd change, including the 3rd change, and generating new config change so you can revert your operation.

In addition to this you can make change and also request that you config this change for example in another 30 seconds. This is cool when you cut yourself out of the system, or the network is down. Then the change is automatically rollbacked. You can do this via „commit confirmed 30“ This is 30 seconds.

You can also do „commit label this is my ospf change mada facka“ you can add string to your change. You can then list that via „show config commit list“ or „show config commit list detail“

The IOS XR can also warn you if you are configuring the box with someone else who has also uncommitted changes. Also some changes may fail. When you configure something what doesnt make sense the XR wont warn you inline, but after the committing, the commit will fail. You can then list why it failed via the „show config failed“ command. This failed operation will fail the whole config not just the wrong lines – cool. However when config fail, you are reverted to the config mode with your candidate config. You can do „abort“ to delete the candidate config and start again. Cool! What if you want to commit everything whatever can be committed and fail just the bad config? You can do it via command „commit best-effort“

In XR there is no difference between startup config and running config. The only config we have is the running config. Also if you want to replace the whole running config with whatever you have in your candidate config you can do it via „commit replace“. If you have nothing in the candidate config you will erase the running config – it will be empty 😀