Editing the running configurationΒΆ

The edition model is transactional. The running configuration is first fetched locally. This local copy, called staging configuration, can be modified locally, then committed. The running configuration can be set as startup configuration.

../../../_images/edit-config.svg

Enter into the edition mode with:

vsr> edit running
vsr running config#

In edition mode, the prompt is composed of:

  • the hostname,

  • the name of the configuration being edited (here running),

  • the path of the current node in the configuration tree (here /, which means we are at the root),

  • a #, meaning we are in the edition mode.

A ! can also be displayed at the end of the prompt when the staging configuration is invalid regarding the constraints defined in the YANG model. The validate command can then be used to check what is invalid in the configuration:

vsr running interface# physical eth1
vsr running physical eth1#! validate
ERR ly Missing required element "port" in "physical".
Invalid configuration.
vsr running physical eth1#! port pci-b0s2
vsr running physical eth1#

In edition mode, the user can:

  • modify the staging configuration (ex: vrf main ssh-server)

  • show the staging configuration (ex: show config)

  • commit the changes (ex: commit)

  • commit the changes with confirmation (ex: commit confirmed period 60 persist-id 1)

  • cancel a (confirmed) commit: (ex: cancel or cancel persist-id 1)

  • confirm a (confirmed) commit (ex: confirm or confirm persist-id 1)

  • discard the changes (ex: exit)

  • display the help of a command (ex: help show)

  • retrieve the state of the device (ex: show state)

  • update the startup configuration of the device (copy running startup)

  • send commands (ex: cmd reboot)