This article explains how to copy and paste a configuration from a text file on to the SRX firewall.
Need to copy and paste a configuration from a text file on to the SRX firewall
The command " load replace terminal " can be used to copy a configuration snippet from a text file to the SRX firewall. After you execute this command, the firewall will start accepting configuration data via the paste option and will replace the existing configuration. Use the CTRL-D or ^D option to exit the terminal mode and return to the firewall prompt.
load replace terminal
CTRL-D
^D
A sample example is shown below:
root@SRX# load replace terminal [Type ^D at a new line to end input] interfaces { ge-0/0/0 { unit 0 { family inet { address 192.168.100.1/24; } } } ge-0/0/3 { speed 100m; link-mode full-duplex; gigether-options { no-auto-negotiation; } unit 0 { family inet { address 172.19.51.157/23; } } } } load complete [edit] root@SRX# commit
root@SRX# load replace terminal [Type ^D at a new line to end input] interfaces { ge-0/0/0 { unit 0 { family inet { address 192.168.100.1/24; } } } ge-0/0/3 { speed 100m; link-mode full-duplex; gigether-options { no-auto-negotiation; } unit 0 { family inet { address 172.19.51.157/23; } } } } load complete
[edit] root@SRX# commit
See also KB16622 - SRX Getting Started - Copy/Paste Configuration [juniper.net] for additional reference.
2020-04-27: Article reviewed for accuracy; minor changes made and article made relevant to SRX series devices