Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Working with configuration

Configuration basics

Terminology

Several versions of system configuration information exist on the system at a given time.

  • Active or “running” configuration

    • This configuration is the one that is loaded and being used by the system.

  • Candidate configuration

    • When you enter configuration mode and make configuration changes, changes remain in candidate configuration until you commit the changes, at which time the configuration becomes active or running.

Configuration hierarchy

DANOS vRouter configuration is organized as a hierarchy of configuration statements, with a hierarchical tree of nodes similar to the directory structure on a UNIX file system. Three kinds of statements exist:

  • Configuration nodes. These nodes can be either

...

...

    • Single-nodes (just one instance can be created; for example, the

...

    • service ssh timeout)

...

    • Multi-nodes (more than one instance can be created; for example,

...

    • service ssh port)

...

  • Attribute statements. These statements set the values or characteristics for parameters within a node.

From a system perspective, a configuration node is different from a simple configuration attribute statement. A configuration attribute statement takes the form attribute value, as in the following example.

protocol-version v2

A configuration node always has an enclosing pair of braces, which may be empty, as in the following example,

...

Navigating in configuration mode

You can tell where you are in the configuration tree by the [edit] prompt, which is context sensitive.

At the top of the configuration tree, the [edit] prompt looks like this:
[edit]
When you are in another location, the edit prompt indicates your location by showing the node hierarchy in order, like this:
[edit service ssh]

The following commands for navigating in configuration mode are available:

  • edit config-node

    • Navigates to the specified configuration node for editing.

    • The node must already be created the configuration committed.

  • exit

    • Jumps to the top of the configuration tree.

    • If you are already at the top of the configuration tree, exit from configuration mode and return to operational mode.

  • top

    • Jumps to the top of the configuration tree.

  • up

    • Moves up one node in the configuration tree.

Viewing configuration in configuration mode

Use the show command in configuration mode to display configuration. You can restrict the display to a particular node by specifying the path to the node.

The following example shows how to display configuration for all configured interfaces.

Code Block
languagetext
vyatta@R1# show interfaces
 interfaces {
        dataplane dp0p1s1 {
                address 10.10.1.1/24
        }
        dataplane dp0s2 {
                address dhcp
        }
        loopback lo
 }

The following example shows how to display configuration for only the dp0p1s1 dataplane interface.

Code Block
languagetext
vyatta@R1# show interfaces dataplane dp0p1s1
 dataplane dp0p1s1 {
        address 10.10.1.1/24
 }


When the display is too large for one screen, the display stops after one screen is shown. In this case, press one of the following keys to perform the indicated action.

  • <Enter> to display the next line

  • <Space> to display the next screen

  • <q> to interrupt the display and return to the command prompt

Viewing configuration in operational mode

You can display configuration information without leaving operational mode by using the show configuration command, as in the following example.

Code Block
languagetext
vyatta@R1:~$ show configuration
interfaces {                                                                                                  [0/3747]
        dataplane dp0p1s1 {
                address 10.10.1.1/24
        }
        dataplane dp0s2 {
                address dhcp
        }
        loopback lo
}
service {
        netconf
        ssh {

...


                port 22
                port 830
        }
        telnet
}

Changing configuration information

Managing system configuration