Fortinet white logo
Fortinet white logo
7.6.1

CLI commands

CLI commands

The following table describes commonly used CLI commands.

Command Description
? Show help information.

get system status

Retrieve the current status and basic system information.

Output Example:

Version: FortiData-KVM 7.6.1 build0081 20250610

Hostname: My_FortiData

System time: Tue Jun 10 12:04:09 PDT 2025

System uptime: 6 minutes

Data Disk: Available

Parameter

Description

Version Current firmware version and build date.
Hostname Device hostname.
System time Current system date and time.
System uptime Duration since last reboot.
Data Disk Status of the data storage disk.

show full-configuration

Displays the complete configuration of the system, including all modules and settings.

show system hostname Show hostname configuration.
show system interface Show network interfaces and configurations.
show system route Show all system routes.
show system config route Show configured static routes.
show system setting Show system-level settings.

show system tunneling

Show tunneling (e.g., proxy) configurations.

show user

Show current user.

show timezone help

Show the timezone identifier and its corresponding GMT offset.

config system hostname Set the host name for this appliance.
config system interface

Configure network interfaces.

config system interface

edit mgmt

set ip 172.173.1.200 255.255.255.0

set mode <manual|dhcp>

end

end
config system route Configure the gateway address for the management port.
config system route
set gateway 172.173.1.248
end
config system tunneling Configure license update proxy settings.
config system tunneling
set address <proxy-address>
    set port <proxy-port>
    set status <enable|disable>
    set username <proxy-username>
    set password <proxy-password>
end
diagnose hardware info 

Show hardware information.

diagnose hardware deviceinfo

Show device information.

diagnose daemon

Control and inspect the status of internal system services (daemons).

Sub-command

Description

start Start a specific daemon.
stop Stop a specific daemon.
restart Restart a specific daemon.
status Show the status of a daemon.

The following daemons are supported:

  • scan_analyzer

  • scheduler

  • db_refresh

  • scan_dispatcher

  • scan_downloader

  • scan_event_handler

  • api_http

  • api_https

  • api_local

  • http2

  • log_daemon

  • scan_protection_engine

  • report_generator

  • system

  • all (to target all services)

Examples:

  • diagnose daemon restart api_https

  • diagnose daemon status scheduler

  • diagnose daemon start all

diagnose db

Upgrade the system database to a specific release version or the latest available.

Examples:

  • diagnose db latest

  • diagnose db 7.6.1

diagnose fds connect

Manually trigger a connection to the Fortinet Distribution Server (FDS) to check for updates or validate connectivity.

diagnose logs

Display, delete, or get statistics on logs for individual system modules.

The following modules are supported:

api, analyzer, global_cache, http2, log_daemon, recycle, scan, system, daemon, db, report,d_scan_analyzer, d_scan_download, d_scan_elistener, d_scan_action, d_scan_dispatch,d_app_https, d_app_local, d_app_http, d_logd, d_system, d_apscheduler, d_http2, d_report

Examples:

  • diagnose logs show scan 50
  • diagnose logs show api all | grep 'error'
  • diagnose logs delete scan
  • diagnose logs delete all
  • diagnose logs stats report
  • diagnose logs stats all

execute backup

Back up the system configuration to a TFTP server.

Syntax:

execute backup <type> tftp <file_name> <tftp_server_ip>, where type can be any of the following:

Value

Description

all

Back up both system and data protection configurations.

config Back up data protection configuration only.
system Back up system configuration only.

Example:

execute backup all tftp full_backup.zip 10.10.10.100

execute ping

Send ICMP echo requests to a host to test network connectivity.

Example:

execute ping 8.8.8.8

execute reboot Reboot the system.
execute shutdown Shut down the system.
execute restore

Restore system configuration, upgrade firmware image, or update VM license from a remote server.

Syntax:

execute restore <type> <protocol> <file_name> <server_ip>

Type

Supported Protocols

Description

config tftp Restore system configuration from TFTP server.
image tftp, ftp Upgrade firmware image from TFTP/FTP server.
vmlicense tftp Update VM license from TFTP server.

Examples:

  • execute restore config tftp full_backup.zip 10.255.255.171

  • execute restore image tftp image_20250601.out 10.255.255.171

  • execute restore image ftp image_20250601.out 192.168.1.200

  • execute restore vmlicense tftp license.lic 10.255.255.171

exit Exit the current session.

CLI commands

CLI commands

The following table describes commonly used CLI commands.

Command Description
? Show help information.

get system status

Retrieve the current status and basic system information.

Output Example:

Version: FortiData-KVM 7.6.1 build0081 20250610

Hostname: My_FortiData

System time: Tue Jun 10 12:04:09 PDT 2025

System uptime: 6 minutes

Data Disk: Available

Parameter

Description

Version Current firmware version and build date.
Hostname Device hostname.
System time Current system date and time.
System uptime Duration since last reboot.
Data Disk Status of the data storage disk.

show full-configuration

Displays the complete configuration of the system, including all modules and settings.

show system hostname Show hostname configuration.
show system interface Show network interfaces and configurations.
show system route Show all system routes.
show system config route Show configured static routes.
show system setting Show system-level settings.

show system tunneling

Show tunneling (e.g., proxy) configurations.

show user

Show current user.

show timezone help

Show the timezone identifier and its corresponding GMT offset.

config system hostname Set the host name for this appliance.
config system interface

Configure network interfaces.

config system interface

edit mgmt

set ip 172.173.1.200 255.255.255.0

set mode <manual|dhcp>

end

end
config system route Configure the gateway address for the management port.
config system route
set gateway 172.173.1.248
end
config system tunneling Configure license update proxy settings.
config system tunneling
set address <proxy-address>
    set port <proxy-port>
    set status <enable|disable>
    set username <proxy-username>
    set password <proxy-password>
end
diagnose hardware info 

Show hardware information.

diagnose hardware deviceinfo

Show device information.

diagnose daemon

Control and inspect the status of internal system services (daemons).

Sub-command

Description

start Start a specific daemon.
stop Stop a specific daemon.
restart Restart a specific daemon.
status Show the status of a daemon.

The following daemons are supported:

  • scan_analyzer

  • scheduler

  • db_refresh

  • scan_dispatcher

  • scan_downloader

  • scan_event_handler

  • api_http

  • api_https

  • api_local

  • http2

  • log_daemon

  • scan_protection_engine

  • report_generator

  • system

  • all (to target all services)

Examples:

  • diagnose daemon restart api_https

  • diagnose daemon status scheduler

  • diagnose daemon start all

diagnose db

Upgrade the system database to a specific release version or the latest available.

Examples:

  • diagnose db latest

  • diagnose db 7.6.1

diagnose fds connect

Manually trigger a connection to the Fortinet Distribution Server (FDS) to check for updates or validate connectivity.

diagnose logs

Display, delete, or get statistics on logs for individual system modules.

The following modules are supported:

api, analyzer, global_cache, http2, log_daemon, recycle, scan, system, daemon, db, report,d_scan_analyzer, d_scan_download, d_scan_elistener, d_scan_action, d_scan_dispatch,d_app_https, d_app_local, d_app_http, d_logd, d_system, d_apscheduler, d_http2, d_report

Examples:

  • diagnose logs show scan 50
  • diagnose logs show api all | grep 'error'
  • diagnose logs delete scan
  • diagnose logs delete all
  • diagnose logs stats report
  • diagnose logs stats all

execute backup

Back up the system configuration to a TFTP server.

Syntax:

execute backup <type> tftp <file_name> <tftp_server_ip>, where type can be any of the following:

Value

Description

all

Back up both system and data protection configurations.

config Back up data protection configuration only.
system Back up system configuration only.

Example:

execute backup all tftp full_backup.zip 10.10.10.100

execute ping

Send ICMP echo requests to a host to test network connectivity.

Example:

execute ping 8.8.8.8

execute reboot Reboot the system.
execute shutdown Shut down the system.
execute restore

Restore system configuration, upgrade firmware image, or update VM license from a remote server.

Syntax:

execute restore <type> <protocol> <file_name> <server_ip>

Type

Supported Protocols

Description

config tftp Restore system configuration from TFTP server.
image tftp, ftp Upgrade firmware image from TFTP/FTP server.
vmlicense tftp Update VM license from TFTP server.

Examples:

  • execute restore config tftp full_backup.zip 10.255.255.171

  • execute restore image tftp image_20250601.out 10.255.255.171

  • execute restore image ftp image_20250601.out 192.168.1.200

  • execute restore vmlicense tftp license.lic 10.255.255.171

exit Exit the current session.