FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
Not applicable
Article Id 191282
Article
DescriptionUsing Runtime-only configurations to test CLI commands
Components
  • All FortiGate units running 3.0 MR2 or higher.
Steps or Commands

Runtime-only config mode is a temporary mode where the commands you enter do not automatically become part of your FortiGate unit's saved configuration. This enables you to make changes with the knowledge that you can revert to the saved configuration if there are problems.

NOTE: Backup your configuration before experimenting with this feature. Otherwise you may lose your working configuration data.

The commands related to Runtime-only config mode are:

config system global
  set cfg-save { automatic | manual | revert }
  set cfg-revert-timeout <seconds>
end

execute cfg reload
execute cfg save

The default setting for cfg-save is automatic mode where CLI commands become part of the saved unit configuration as soon as you execute them by entering either next or end.

In manual mode, commands take effect but do not become part of the saved configuration unless you execute the execute cfg save command. When the FortiGate unit restarts, it loads the saved configuration. Configuration changes that were not saved are lost. This allows you to test commands, before you save them and revert to a working configuration if required.

Revert mode is manual mode with the added feature that if your administrative session is idle for more than a specified timeout period your FortiGate unit will reboot using the last saved configuration. You set the timeout delay in system global using the set cfg-revert-timeout command. This is useful if you are locked out of your FortiGate unit due to changes you made. After waiting for the timeout period, you can logon again like normal.

You can read about these commands in the FortiGate CLI Reference.