If, in an override or merge operaon, you specify a le or type text that contains replace: tags, the replace:
tags are ignored. In this scenario, the override or merge operaon takes precedence and is performed.
If you are performing a replace operaon, and if the le that you specify lacks replace: tags, the replace
operaon runs as a merge operaon. The replace operaon also runs as a merge operaon if the text you
type lacks replace: tags. This informaon might be useful if you are running automated scripts and
cannot know in advance whether the scripts need to perform a replace operaon or a merge operaon.
The scripts can use the replace operaon to cover either case.
The load merge operaon merges the conguraon from the saved le or terminal with the exisng
candidate conguraon. This informaon is useful if you are adding new conguraon secons. For
example, suppose that you are adding a BGP conguraon to the [edit protocols] hierarchy level, where
there was no BGP conguraon before. You can use the load merge operaon to combine the incoming
conguraon with the exisng candidate conguraon. If the exisng conguraon and the incoming
conguraon contain conicng statements, the statements in the incoming conguraon override
those in the exisng conguraon.
To replace only those parts of the conguraon that have changed, you specify the update opon at any
level of the hierarchy. The load update operaon compares the candidate conguraon and the new
conguraon data. This operaon changes only those parts of the candidate conguraon that are
dierent from the new conguraon. You would use this operaon, for example, if there is an exisng
BGP conguraon and the le you are loading changes it in some way.
The merge, override, and update opons support loading conguraon data in JavaScript Object Notaon
(JSON) format. When loading conguraon data that uses JSON format, you must specify the json
opon in the command. To load JSON conguraon data that contains unordered list entries, that is, list
entries where the list key is not necessarily the rst element in the list entry, see "Load JSON
Conguraon Data With Unordered List Entries" on page 246.
To change part of the conguraon with a patch le, you specify the patch opon. The load patch
operaon loads a le or terminal input that contains conguraon changes. First, on a device that
already has the conguraon changes, you type the show | compare command to output the dierences
between two conguraons. Then you can load the dierences on another device. The advantage of the
load patch command is that it saves you from having to copy snippets from dierent hierarchy levels into
a text le before loading them into the target device. This might be a useful me saver if you are
conguring several devices with the same opons. For example, suppose that you congure a roung
policy on router1 and you want to replicate the policy conguraon on router2, router3, and router4.
You can use the load patch operaon.
In this example, you rst run the show | compare command.
233