[Contents] [Prev] [Next] [Index] [Report an Error]

Creating New Configuration Elements

To create new configuration elements (hierarchy levels or configuration objects), a client application includes the basic tag elements or formatted ASCII statements described in Creating, Modifying, or Deleting Configuration Elements.

New elements can be created in either merge mode or replace mode, which are described in Merging Configuration Elements and Replacing Configuration Elements. In replace mode, the application includes the action="replace" attribute in the <load-configuration/> tag or opening <load-configuration> tag.

To use JUNOS XML tag elements to represent the element, the application includes each of the replacement’s identifier tag elements (if it has them) and all child tag elements being defined for the element. In the following, the identifier tag element is called <name>. The application does not need to include any attributes in the opening container tag for the new element:

<configuration>
<!- - opening tag for each parent of the element - ->
<container-tag>
<name>identifier</name>
<!- - tag elements for other children, if any - ->
</container-tag>
<!- - closing tag for each parent of the element - ->
</configuration>

To use formatted ASCII text to represent the element, the application includes each of the replacement’s identifiers (if it has them) and all child statements (with values if appropriate) that it is defining for the element. It does not need to include an operator before the new element:

<configuration-text>
/* statements for parent levels of the element */
element identifier {
/* child statements if any */
}
/* closing braces for parent levels for the element */
</configuration-text>

[Contents] [Prev] [Next] [Index] [Report an Error]