Description

This is an example of the "replace pattern" command.

Symptoms

You need to change of an existing VPN

Solution

  • Find the name of the VPN you are looking for:

[edit]

root@KB# show configuration security ike | display set

set security ike gateway GW-VPN-TEST1

 

 

[edit]

root@KB# show configuration security ipsec | display set

set security ike ipsec VPN-TEST1

 

 

 

 

  • Once you know the string that you want to replace, let say in this case "TEST1", you can use "replace pattern string with new-string":

[edit]

root@KB# replace pattern TEST1 with JUNIPER

 

 

[edit]

root@KB# show configuration security ike | display set

set security ike gateway GW-VPN-JUNIPER

 

 

[edit]

root@KB# show configuration security ipsec | display set

set security ike ipsec VPN-Juniper

 

 

 

[edit]

root@KB#commit

 

 

 

Note: This will flap the VPN.

Modification History

2024-08-28 : Article Created