Nagios XI Backup

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
gzarif
Posts: 38
Joined: Thu Mar 26, 2015 9:44 am

Nagios XI Backup

Post by gzarif »

Hi,

How do I do a scheduled backup?

I think the only way I can is the Local backup but i always get The directory is likely not writeable by user 'nagios' or group 'nagios' - check permissions

Please advise.

Thanks,

G.
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: Nagios XI Backup

Post by jolson »

It sounds like you're already this far, but you can specify local backups (in addition to SSH or FTP backups) at the following page:
2015-05-11 14_09_57-Nagios XI - Administration.png
If you hit test permissions and you're getting a permissions problem, that means that the directory you've selected for backups is probably not read/write-able by the 'nagios' user. To test this, log into the nagios device using SSH or similar, and run the following command:

Code: Select all

ls -l <backup directory here>
For example, if I chose /nagiosbackups/backups as my directory of choice, I would run:

Code: Select all

ls -l -d /nagiosbackups/backups
This will give us a list of permissions for that directory.
ls -l -d /nagiosbackups/backups
drwxr-xr-x 2 root root 4096 May 11 15:12 /nagiosbackups/backups
Note that drwxr-xr-x are the read-write permissions, and root root is the owner/group.

You will want this directory to be owned by nagios/nagios, and the nagios user needs proper permissions. Following my example, we'll change the directory permissions with the following command:

Code: Select all

chmod u+rw /nagiosbackups/backup
chmod g+rw /nagiosbackups/backup
chown nagios:nagios /nagiosbackups/backup
Let's check the permissions now...
ls -ld /nagiosbackups/backups/
drwxrwxr-x 2 nagios nagios 4096 May 11 15:12 /nagiosbackups/backups/
Looks good - run 'test permissions' once more and you should see it pass successfully.
You do not have the required permissions to view the files attached to this post.
Twits Blog
Show me a man who lives alone and has a perpetually clean kitchen, and 8 times out of 9 I'll show you a man with detestable spiritual qualities.
Locked