Friday, December 7, 2018

SCP config backup, config restore and image restore

Works in 5.2.x and up.
Restoring the image to the primary partition will trigger an immediate upgrade/downgrade including reboot.

These all require admin-scp to be enabled on the target device
config global
config system global
set admin-scp enable

#Config Backup

scp admin@<fgthostname>:fgt-config <fgthostname>.conf

scp admin@myfgt1:fgt-config myfgt1.conf

#Config Restore

scp <fgthostname>.conf admin@<fgthostname>:fgt-restore-config 

scp myfgt1.conf admin@myfgt1:fgt-restore-config 

#Image Upload to Primary Partition

scp <fgtimagename> admin@<fgthostname>:fgt-image

scp FGT_3700D-v5-build1600-FORTINET.out admin@myfgt1:fgt-image

#Image Upload to Secondary Partition

scp <fgtimagename> admin@<fgthostname>:fgt-secondary-image

scp FGT_3700D-v5-build1600-FORTINET.out admin@myfgt1:fgt-secondary-image