NagiosXI restore problem

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Fred Kroeger
Posts: 588
Joined: Wed Oct 19, 2011 11:36 pm
Location: Perth, Western Australia
Contact:

Re: NagiosXI restore problem

Post by Fred Kroeger »

Thanks - I downloaded both the backup & restore scripts. It still fails at the first step because it can't find the file my-hostname/nagios.tar.gz in the tarball because it is saved with the timestamp -
# tar tzf /store/backups/nagiosxi/my-hostname.tar.gz | grep nagios.tar.gz
1395034202/nagios.tar.gz

This is how I ran the commands:
Create the Backup

Code: Select all

/usr/local/nagiosxi/scripts/backup_xi-update.sh -n `/bin/hostname -s`
Restore

Code: Select all

# cd /store/backups/nagiosxi

# /usr/local/nagiosxi/scripts/restore_xi-update.sh /store/backups/nagiosxi/my-hostname.tar.gz
tar: [b]my-hostname/nagios.tar.gz[/b]: Not found in archive
tar: Exiting with failure status due to previous errors

gzip: stdin: unexpected end of file
tar: Child returned status 1
tar: Error is not recoverable: exiting now
WARNING: you are trying to restore a  backup on a 64-bit system
         Plugins and other binaries will NOT be restored.

Are you sure you want to continue? [y/N]
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NagiosXI restore problem

Post by lmiltchev »

If you type "y" and hit "Enter" to continue
Are you sure you want to continue? [y/N]
are you able to restore successfully (regardless of what the message says)?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Fred Kroeger
Posts: 588
Joined: Wed Oct 19, 2011 11:36 pm
Location: Perth, Western Australia
Contact:

Re: NagiosXI restore problem

Post by Fred Kroeger »

Yes - with this version of the restore script it does complete successfully after I enter the "y"
So now we are still left with the initial error as I can't run the restore via cron and I don't want to fudge it by sending a 'Y' as it then won't restore the plugins and other binaries.

Fred
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NagiosXI restore problem

Post by lmiltchev »

So now we are still left with the initial error as I can't run the restore via cron and I don't want to fudge it by sending a 'Y' as it then won't restore the plugins and other binaries.
I see what you mean. I created a new internal bug report/testing task. As this is not an *actual* bug (backup/restore works fine if you follow the steps, outlined in our docs), it may take some time before/if we fix the issue (not a priority issue). We will let you know when we have a possible solution for you.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Fred Kroeger
Posts: 588
Joined: Wed Oct 19, 2011 11:36 pm
Location: Perth, Western Australia
Contact:

Re: NagiosXI restore problem

Post by Fred Kroeger »

Thanks - though I'm more inclined to think it is a bug as you are trying to restore a file from a path in the tarball that only exists if the timestamp is used as the tarball filename.
This daily export/import is part of the HA strategy I've employed at this site, so it would be really helpful (to me!) to get a resolution on this sooner rather than later.
- Prod server exports Nagios files & configs
- DR server pulls backup file & imports into Nagios
- Prod Server updates DR Server via NSCA

regards... Fred
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: NagiosXI restore problem

Post by scottwilkerson »

Fred,

We actually did change this internally and it will be in 2014 when released.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Fred Kroeger
Posts: 588
Joined: Wed Oct 19, 2011 11:36 pm
Location: Perth, Western Australia
Contact:

Re: NagiosXI restore problem

Post by Fred Kroeger »

Thanks Scott!
Locked