load-configuration tag (JUNOScript)action attribute (JUNOScript)load-configuration tagformat attribute (JUNOScript)load-configuration tagrescue attribute (JUNOScript)load-configuration tagrollback attribute (JUNOScript)load-configuration tagurl attribute (JUNOScript)load-configuration tag
<rpc>
<load-configuration rescue="rescue"/>
<load-configuration rollback="index"/>
<load-configuration url="url " [action="(merge | override | replace | update)"] \
[format="(text | xml)"]/>
<load-configuration format="text" [action="(merge | override | replace | \
update)"]>
<configuration-text>
<!- - formatted ASCII configuration statements to load - ->
</configuration-text>
</load-configuration>
<load-configuration [action="(merge | override | replace | update)"] \
[format="xml"]>
<configuration>
<!- - tag elements for configuration elements to load - ->
</configuration>
</load-configuration>
</rpc>
Request that the JUNOScript server load configuration data into the candidate configuration. Provide the data to load in one of four ways:
In the following example, the url attribute identifies /tmp/add.conf as the file to load. (The omission of the format attribute indicates that the file contains JUNOS XML tag elements.)
- <load-configuration url="/tmp/add.conf"/>
action—Specifies how to load the configuration data, particularly when the candidate configuration and loaded configuration contain conflicting statements. The following are acceptable values:
If providing the configuration data as formatted ASCII text (either in the file named by the url attribute or enclosed in a <configuration-text> tag element), also place the replace: statement on the line directly preceding the statements that represent the hierarchy level or object to replace. For more information, see the discussion of loading a file of configuration data in the JUNOS CLI User Guide.
If providing the configuration data as JUNOS XML tag elements, also set the replace attribute to the value replace on the opening tag of the container tag element that represents the hierarchy level or object to replace.
format—Specifies the format used for the configuration data. There are two acceptable values:
rescue—Specifies that the rescue configuration replace the current candidate configuration. The only valid value is rescue.
rollback—Specifies the numerical index of the previous configuration to load. Valid values are 0 (zero, for the most recently committed configuration) through one less than the number of stored previous configurations (maximum is 49).
url—Specifies the full pathname of the file that contains the configuration data to load. The value can be a local file path, an FTP location, or a Hypertext Transfer Protocol (HTTP) URL:
- ftp://username:password@hostname/path/filename
A filename on an HTTP server has the following form:
- http://username:password@hostname/path/filename
In each case, the default value for the path variable is the home directory for the username. To specify an absolute path, the application starts the path with the characters %2F; for example, ftp://username:password@hostname/%2Fpath/filename.
See Changing Configuration Information.
<load-configuration-results>, <rpc>, replace, entries for <configuration> and <configuration-text> in the JUNOS XML API Configuration Reference