Skip to main content
tp-italia
New Member
May 15, 2023
Question

backup via ftp

  • May 15, 2023
  • 8 replies
  • 8459 views

Dear, i want to configure a schedule backup of my HA firewall 100F .

 I tried to exe this command via cli

 

execute backup config ftp /backupFW/backup_%date%.cfg 10.10.X.X backupfw test1

 

but i have this error:

 

Send config file to ftp server via vdom root failed

Command fail. Return code 12

 

I tested the ftp account with filezilla and i can log on the Ftp Server and the user had the RW permession on the ftp folder .

 

thanks

Antonio

8 replies

pavankr5
Staff
Staff
May 15, 2023

Hello @tp-italia,

Could you please confirm if it is a new setup or was it working before.

 

The error message you received indicates that there was a problem sending the configuration file to the FTP server.
Check the firewall settings on both the FortiGate and the FTP server to ensure that FTP traffic is allowed.

Verify that the FTP username and password are correct and have the necessary permissions to write to the backup folder.
Verify that the backup folder exists and has the correct permissions.

https://community.fortinet.com/t5/FortiGate/Technical-Tip-How-to-send-automated-backups-of-the-configuration/ta-p/198364 


Backup of configuration file from CLI using FTP 

https://community.fortinet.com/t5/FortiGate/Technical-Tip-Backup-of-configuration-file-from-CLI-using-FTP/ta-p/212891

tp-italia
tp-italiaAuthor
New Member
May 15, 2023

Hi Pavankr5, this is a new setup for ftp service .

 

But i Resolve it with TFTP and not with FTP .

 

Is there a way to add the date to the file?

 

thanks

 

 

funkylicious
SuperUser
SuperUser
May 15, 2023

Hi,
If I recall corectly, manually setting that variable and executing the script won't display the date, you would need to create a automation task and it will be good.

"jack of all trades, master of none"
rtichkule
Staff
Staff
May 17, 2023

Hello,

 

The command "execute backup config ftp backup.cfg 10.10.X.X backupfw test1" will generate a configuration backup file in the directory which is set in the FTP server. However the command "execute backup config ftp /backupFW/backup_%date%.cfg 10.10.X.X backupfw test1" will generate the backup in the directory /backupFW
If there is no directory with such name the server will respond with the error.

Either you can create a directory /backupFW in which the configuration backup will be saved or you can remove the path so that the backup will be saved in the current directory which is configured in the FTP server.

 

BR

Thought Leadership Security Summit. Outpace New Threats with AI - enhanced defense. Tuesday, Septmeber 15, 8:30 AM - 2:30 PM PT. The Golf Club at Newcastle, WA.
Virtual event | September 2026. SASE summit. The age of autonomous trust. Register here!