Fortinet black logo

Backing up and restoring CLI utility commands and syntax

Backing up and restoring CLI utility commands and syntax

Fortinet provides administrators the ability to import and export configurations via the CLI. The system or admin user can run the fcconfig utility locally or remotely to import or export the configuration file. In Windows, the fcconfig utility is located in the C:\Program Files (x86)\Fortinet\FortiClient> directory. In macOS, the fccconfig utility is located in the /Library/Application Support/Fortinet/FortiClient/bin directory.

The following commands are available for use:

Command

Description

FCConfig -m all -f <filename> -o export -i 1

Back up the configuration file.

FCConfig -m all -f <filename> -o export -i 1 -p <encrypted password>

Back up the configuration file (encrypted).

FCConfig -m all -f <filename> -o import -i 1

Restore the configuration file.

FCConfig -m all -f <filename> -o import -i 1 -p <encrypted password>

Restore the configuration file (encrypted).

FCConfig -m vpn -f <filename> -o exportvpn -i 1

Export the VPN tunnel configuration.

FCConfig -m vpn -f <filename> -o exportvpn -i 1 -p <encrypted password>

Export the VPN tunnel configuration (encrypted).

FCConfig -m vpn -f <filename> -o importvpn -i 1

Import the VPN tunnel configuration.

FCConfig -m vpn -f <filename> -o importvpn -i 1 -p <encrypted password>

Import the VPN tunnel configuration (encrypted).

Switches and switch parameters are case-sensitive.

Backing up and restoring CLI commands are advanced configuration options.

The command fccconfig -f settings.xml -m all -o export exports the configuration as an XML file in the FortiClient directory.

Backing up and restoring CLI utility commands and syntax

Backing up and restoring CLI utility commands and syntax

Fortinet provides administrators the ability to import and export configurations via the CLI. The system or admin user can run the fcconfig utility locally or remotely to import or export the configuration file. In Windows, the fcconfig utility is located in the C:\Program Files (x86)\Fortinet\FortiClient> directory. In macOS, the fccconfig utility is located in the /Library/Application Support/Fortinet/FortiClient/bin directory.

The following commands are available for use:

Command

Description

FCConfig -m all -f <filename> -o export -i 1

Back up the configuration file.

FCConfig -m all -f <filename> -o export -i 1 -p <encrypted password>

Back up the configuration file (encrypted).

FCConfig -m all -f <filename> -o import -i 1

Restore the configuration file.

FCConfig -m all -f <filename> -o import -i 1 -p <encrypted password>

Restore the configuration file (encrypted).

FCConfig -m vpn -f <filename> -o exportvpn -i 1

Export the VPN tunnel configuration.

FCConfig -m vpn -f <filename> -o exportvpn -i 1 -p <encrypted password>

Export the VPN tunnel configuration (encrypted).

FCConfig -m vpn -f <filename> -o importvpn -i 1

Import the VPN tunnel configuration.

FCConfig -m vpn -f <filename> -o importvpn -i 1 -p <encrypted password>

Import the VPN tunnel configuration (encrypted).

Switches and switch parameters are case-sensitive.

Backing up and restoring CLI commands are advanced configuration options.

The command fccconfig -f settings.xml -m all -o export exports the configuration as an XML file in the FortiClient directory.