Offloading MySQL & xi-sys.cfg
Re: Offloading MySQL & xi-sys.cfg
Apologies. Here you go:
A local backup completes in 10 mins. I've watched the cmdsubsys.log file at the time of the schedule when it hasn't worked. It doesn't actually fire the cron command to run the backup and no local files created in /store/backups/nagiosxi. I've watched a successful run and I can see the cron command being fired and the local files being created before copied via ssh.
A local backup completes in 10 mins. I've watched the cmdsubsys.log file at the time of the schedule when it hasn't worked. It doesn't actually fire the cron command to run the backup and no local files created in /store/backups/nagiosxi. I've watched a successful run and I can see the cron command being fired and the local files being created before copied via ssh.
You do not have the required permissions to view the files attached to this post.
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: Offloading MySQL & xi-sys.cfg
@andyb4u, Please delete all the backups from the /store/backups/nagiosxi/ folder, or move them to another folder, for now. In the "Scheduled Backups" menu please click on the local backups tab, click on test permission, check the location, change the scheduled backup time, click on enable local backups and click on Update Settings. The goal here is to see whether local scheduled backups are still working with their original settings.
After the scheduled backup time is due, give it another hour and then run the ls -l on the /store/backups/nagiosxi/ folder one more time. Please share the screenshot.
After the scheduled backup time is due, give it another hour and then run the ls -l on the /store/backups/nagiosxi/ folder one more time. Please share the screenshot.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Offloading MySQL & xi-sys.cfg
I've done those steps and here is the result
It hasn't run successfully.
Tail from the scheduledbackups.log file
12-15-2017 07:40:01 INFO: Creating a local backup: nagiosxi.1513323601
12-15-2017 07:40:01 DEBUG: Sending create local backup command to CmdSubsystem
Nothing in cmdsubsys around the time of the schedule.
It hasn't run successfully.
Tail from the scheduledbackups.log file
12-15-2017 07:40:01 INFO: Creating a local backup: nagiosxi.1513323601
12-15-2017 07:40:01 DEBUG: Sending create local backup command to CmdSubsystem
Nothing in cmdsubsys around the time of the schedule.
You do not have the required permissions to view the files attached to this post.
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: Offloading MySQL & xi-sys.cfg
@andyb4u, Can you go to the admin menu, then click on System information, then Audit log. Can you upload a screenshot of the audit log entries after the scheduled backup was supposed to run? Also, if you haven't upgraded XI to the latest version please do so. There were a few bug fixes related to scheduled backups.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Offloading MySQL & xi-sys.cfg
We are up to date running Nagios XI (5.4.11).
You do not have the required permissions to view the files attached to this post.
Re: Offloading MySQL & xi-sys.cfg
Can you run the following commands and post the output?
This will show us if the backup job was put in to the MYSQL commands table and the layout of the table.
Thanks
Code: Select all
echo 'desc xi_commands;' |mysql -t -u root -pnagiosxi nagiosxi
echo 'select * from xi_commands;' |mysql -t -u root -pnagiosxi nagiosxiThanks
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Offloading MySQL & xi-sys.cfg
This mornings backups failed:
Scheduledbackups.log
12-16-2017 05:30:01 DEBUG: Running scheduled SSH backup ...
12-16-2017 05:30:01 DEBUG: Sending create local backup command to CmdSubsystem
12-16-2017 07:11:16 ERROR: Scheduled SSH Backup Failed: Local file to transfer does not exist
12-16-2017 07:40:02 DEBUG: Running scheduled local backup ...
12-16-2017 07:40:02 INFO: Creating a local backup: nagiosxi.1513410002
12-16-2017 07:40:02 DEBUG: Sending create local backup command to CmdSubsystem
I've attached the results of the 2 MYSQL queries.
The only entry I can see in cmdsubsys.log
...............PROCESSING COMMAND ID 37056...
PROCESS COMMAND: CMD=1119, DATA=a:2:{i:0;s:19:"nagiosxi.1513402201";i:1;s:24:"/store/backups/nagiosxi/";}
CMDLINE=rm -rf /store/backups/nagiosxi/nagiosxi.1513402201.tar.gz
OUTPUT=
RETURNCODE=0
..............................................
PROCESSED 1 COMMANDS
12-16-2017 05:30:01 DEBUG: Running scheduled SSH backup ...
12-16-2017 05:30:01 DEBUG: Sending create local backup command to CmdSubsystem
12-16-2017 07:11:16 ERROR: Scheduled SSH Backup Failed: Local file to transfer does not exist
12-16-2017 07:40:02 DEBUG: Running scheduled local backup ...
12-16-2017 07:40:02 INFO: Creating a local backup: nagiosxi.1513410002
12-16-2017 07:40:02 DEBUG: Sending create local backup command to CmdSubsystem
I've attached the results of the 2 MYSQL queries.
The only entry I can see in cmdsubsys.log
...............PROCESSING COMMAND ID 37056...
PROCESS COMMAND: CMD=1119, DATA=a:2:{i:0;s:19:"nagiosxi.1513402201";i:1;s:24:"/store/backups/nagiosxi/";}
CMDLINE=rm -rf /store/backups/nagiosxi/nagiosxi.1513402201.tar.gz
OUTPUT=
RETURNCODE=0
..............................................
PROCESSED 1 COMMANDS
You do not have the required permissions to view the files attached to this post.
Re: Offloading MySQL & xi-sys.cfg
What OS and release is the MYSQL server running?
What version of MYSQl or MariaDB is the remote server running?
Can you post the MYSQL configuration files from the server?
The /etc/my.cnf file and all of the files in the /etc/my.cnf.d folder if they exist.
Is the time and time zone settings setup on the MYSQL server and do they match the XI server?
Then run the following to repair the mysql database.
Run the following command and post the /tmp/nagiosxi.txt file so we can check and see if all of the tables were created correctly.
Replace xxx.xxx.xxx.xxx with the IP address of the MYSQL server.
The repair of the database may fix the issue so wait until the next scheduled time to see if the backup runs.
What version of MYSQl or MariaDB is the remote server running?
Can you post the MYSQL configuration files from the server?
The /etc/my.cnf file and all of the files in the /etc/my.cnf.d folder if they exist.
Is the time and time zone settings setup on the MYSQL server and do they match the XI server?
Then run the following to repair the mysql database.
Code: Select all
mysqlcheck -f -r -u nagiosxi -pnagios --use_frm --database nagiosxi -h xxx.xxx.xxx.xxxCode: Select all
mysqldump --no-data --databases nagiosxi -u nagiosxi -pnagios -h xxx.xxx.xxx.xxx >/tmp/nagiosxi.txtThe repair of the database may fix the issue so wait until the next scheduled time to see if the backup runs.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Offloading MySQL & xi-sys.cfg
Red Hat Enterprise Linux Server 7.4 (Maipo)What OS and release is the MYSQL server running?
5.5.56-MariaDB MariaDB ServerWhat version of MYSQl or MariaDB is the remote server running?
/etc/my.cnfCan you post the MYSQL configuration files from the server?
Code: Select all
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
max_allowed_packet=512M
bind-address=[i]xxx.xxx.xxx.xxx[/i]
port=3306
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
client.cnf
Code: Select all
#
# These two groups are read by the client library
# Use it for options that affect all clients, but not the server
#
[client]
# This group is not read by mysql client library,
# If you use the same .cnf file for MySQL and MariaDB,
# use it for MariaDB-only client options
[client-mariadb]
Code: Select all
#
# These groups are read by MariaDB command-line tools
# Use it for options that affect only one utility
#
[mysql]
[mysql_upgrade]
[mysqladmin]
[mysqlbinlog]
[mysqlcheck]
[mysqldump]
[mysqlimport]
[mysqlshow]
[mysqlslap]
Code: Select all
#
# These groups are read by MariaDB server.
# Use it for options that only the server (but not clients) should see
#
# See the examples of server my.cnf files in /usr/share/mysql/
#
# this is read by the standalone daemon and embedded servers
[server]
# this is only for the mysqld standalone daemon
[mysqld]
# this is only for embedded server
[embedded]
# This group is only read by MariaDB-5.5 servers.
# If you use the same .cnf file for MariaDB of different versions,
# use this group for options that older servers don't understand
[mysqld-5.5]
# These two groups are only read by MariaDB servers, not by MySQL.
# If you use the same .cnf file for MySQL and MariaDB,
# you can put MariaDB-only options here
[mariadb]
[mariadb-5.5]
I set a schedule and sat and watched it. The same thing happened where it didn't fire the command and no backup was generated.
You do not have the required permissions to view the files attached to this post.
Re: Offloading MySQL & xi-sys.cfg
I talked with one of the developers and they said to login to the XI GUI as another Administrator and submit a new backup job.
It could be that the user ID is corrupted somehow and it may work with another user.
Also, I would like to see the /etc/sudoers file so can you post it here?
It could be that the user ID is corrupted somehow and it may work with another user.
Also, I would like to see the /etc/sudoers file so can you post it here?
Be sure to check out our Knowledgebase for helpful articles and solutions!