ftp backup stopped working

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: ftp backup stopped working

Post by WillemDH »

Tom,

Solved the permission issue. But I'm still having problems:

Code: Select all

tail -f /usr/local/nagiosxi/var/components/scheduledbackups.log
04-07-2015 11:26:01 DEBUG: Running scheduled FTP backup ...
04-07-2015 11:26:01 DEBUG: Sending create local backup command to CmdSubsystem
04-07-2015 11:50:10 ERROR: Scheduled FTP Backup Failed: Local file to transfer does not exist
While getting the error "04-07-2015 11:50:10 ERROR: Scheduled FTP Backup Failed: Local file to transfer does not exist", the backup was in fact still running. It took another 8 minutes before the local backup was created. So Like I said before I'm pretty sure the script is trying to ftp while the backup is not yet finished...

Grtz

Willem
Nagios XI 5.8.1
https://outsideit.net
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: ftp backup stopped working

Post by lmiltchev »

How long does it usually take to do the local backup? You can try removing "half-way-done" backups from the "/store/backups/nagiosxi/" (if you have any), then specifying a timeout for the scheduled backups by adding the following line to "/usr/local/nagiosxi/html/config.inc.php":

Code: Select all

$cfg['backup_timeout'] = 3600;

Note: This is just an example. You can use a different value, depending on your environment.

Restart apache so that changes can take effect:

Code: Select all

service httpd restart
Schedule a new FTP backup and see if the issue is fixed.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: ftp backup stopped working

Post by WillemDH »

Last time I check, it was about 29 minutes it took to complete. But as said, it seems to me the local created backup is in fact complete. It is just trying to ftp before the backup is completed, hence the file does not yet exists.. I'll test you solution tomorrow though.
Nagios XI 5.8.1
https://outsideit.net
cmerchant
Posts: 546
Joined: Wed Sep 24, 2014 11:19 am

Re: ftp backup stopped working

Post by cmerchant »

I will keep this thread open. Keep us updated.
User avatar
snapon_admin
Posts: 952
Joined: Mon Jun 10, 2013 10:39 am
Location: Kenosha, WI
Contact:

Re: ftp backup stopped working

Post by snapon_admin »

Willem, just FYI we had the same problem you're having but with SSH. We don't use FTP, we just SSH our backups to another server, but our backup also takes awhile (~40-60 minutes) so it would close the SSH session before the backup was completed. I modified the backup timeout option to something like 90 minutes and that solved our issue, so hopefully it'll work for you and FTP as well.
cmerchant
Posts: 546
Joined: Wed Sep 24, 2014 11:19 am

Re: ftp backup stopped working

Post by cmerchant »

Thanks for the input on that timeout parameter. We'll let Willem give us an update when his backups run in the am. Thanks.
User avatar
WillemDH
Posts: 2320
Joined: Wed Mar 20, 2013 5:49 am
Location: Ghent
Contact:

Re: ftp backup stopped working

Post by WillemDH »

It seems adding

Code: Select all

$cfg['backup_timeout'] = 3600;
solved the issue. Please close this thread. It might be a good idea to set the above timeout by default?

Thanks all.

Willem
Nagios XI 5.8.1
https://outsideit.net
Locked