Vyatta documentation

Learn how to install, configure, and operate the Vyatta Network Operating System (Vyatta NOS) and Orchestrator, which help drive our virtual networking and physical platforms portfolio.

Show Page Sections

Add or modify a configuration node — set

How to use the set command to add or modify a configuration node.


Add a configuration node

How to use the Vyatta NOS CLI set command to add a configuration node.

Note: When you first start Vyatta NOS, the configuration tree is almost empty except for a few nodes that the system configures automatically. You must create a node for any functionality you want to configure on the system. When a node is created, Vyatta NOS also applies any default values that exist for the attributes of that node.
  1. At the configuration mode prompt, use the set command to set the IP address of the Ethernet interface.
    In this example, we set interface dp0p1p1 to IP address 192.0.2.21/24.
    user@system# set interfaces dataplane dp0p1p1 address 192.0.2.21/24
    [edit]
    user@system#

    Note that the configuration node for the dp0dp1p1 interface already exists, assuming that your system has at least one Ethernet interface. It exists because the system automatically discovers physical interfaces on startup and creates configuration nodes for them. For the same reason, the hardware ID (MAC address) of the dp0dp1p1 interface is also known to the system.

  2. Optional: Use the show command to see the addition.
    user@system# show interfaces dataplane dp0p1p1
    +address 192.0.2.21/24
     hw-id 00:13:46:e6:f6:87
    [edit]
    user@system#

    Notice the plus sign + in front of the new statement. This indicates that you have added this statement to the configuration, but that you have not committed the change yet. The change does not take effect until you commit the configuration with the commit command.

  3. Optional: Use the compare command to see the change.
    user@system# compare
    [edit interfaces dataplane dp0p1p1]
    +address 192.0.2.21/24
    [edit]
    user@system#

Modify a configuration node

How to use the Vyatta NOS CLI set command to modify a configuration node.

For the most part, the process to modify a configuration node is the same as to add a configuration node — you use the set command.

This works for identifiers of nodes that contain a single instance. To change the identifier of a node for which there can be multiple instances (a 'multinode'), such as a DNS server or an IP address for an interface, you must delete the node and recreate it with the correct identifier.

You can modify configuration from the root of the configuration tree or use the edit command to navigate to the part of the tree where you want to make a change or an addition. Edit mode allows you to abbreviate a series of similar configuration commands.