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.

General use of the set command

An overview of the logic of this command.

To create a configuration path in the candidate configuration, you prefix the path with the keyword set. That is, you build a command string with set at its root, and the structure of the string must conform to the configuration path that you want to create.

So, a complete command string in this case could take a form that looks like:

set keyword1 keyword2 <value2> keyword3 keyword4 <value4>

Technically, you could create an identical configuration path one step at a time, through a sequence like this:

set keyword1
set keyword1 keyword2 <value2>
set keyword1 keyword2 <value2> keyword3
set keyword1 keyword2 <value2> keyword3 keyword4 <value4>

But this requires a lot more typing, for no gain.

If the configuration path already exists, then one of two things will happen:

  1. If keyword4 is a single-item keyword, then the system will change the value of <value4> to the whatever value you specified.
  2. If keyword4 is a list-item keyword, it will add the value that you specified as an additional value in the list at this node.

To determine which keywords/nodes are single-item or list-item, use the CLI help feature. A list-item keyword has + in the first column of the CLI help text, while a single-item keyword does not.

Example CLI command string, and help text (note use of the Tab key):

user@system# set policy qos<Tab> 
Possible completions:
   <Enter>  Execute the current command
+> mark-map Mark-map for PCP marking packets
+> name     Quality of Service (QoS) policy
 > platform QoS platform configuration
+> profile  QoS traffic profile
  
[edit]
user@system#

Here you can see that mark-map, name and profile are all list-item keywords, while platform is a single-item keyword.