Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zabbix 3.0 #5

Open
wants to merge 140 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
140 commits
Select commit Hold shift + click to select a range
371beaf
CHG Backup of Zabbix 1.9.x / 2.0.0
maxhq Mar 16, 2012
e0b97c2
Update zabbix-mysql-backupconf.sh
maxhq May 13, 2013
273166c
Update zabbix-mysql-backupconf.sh
dre- Sep 15, 2014
5ec901c
Merge pull request #2 from dre-/patch-2
maxhq Sep 17, 2014
19fdbd2
Delete zabbix-mysql-autopartitioning.sql
maxhq Sep 17, 2014
3759abf
Update README
maxhq Sep 17, 2014
ffea98a
REV Ignore Eclipse .project file
maxhq Sep 17, 2014
6de48f2
NEW Script to load database table names for each Zabbix version from …
maxhq Sep 18, 2014
d93522d
FIX Corrected sorting of versions like "1.8.1rc1" (own sort routine)
maxhq Sep 18, 2014
ab265e6
DOC Added table headers for output
maxhq Sep 18, 2014
372bc02
NEW Added file containing table list up to Zabbix 2.4.0
maxhq Sep 18, 2014
5668edb
DOC Added script description
maxhq Sep 18, 2014
fd60e6a
ENH Complete overhaul so that script works with all previous Zabbix v…
maxhq Oct 2, 2014
bd56ead
REV Show backup progress percentage instead of each table name
maxhq Oct 2, 2014
796d9f5
REV Show backup progress percentage instead of each table name
maxhq Oct 2, 2014
7ef7136
Merge branch 'master' of [email protected]:maxhq/zabbix-backup.git
maxhq Oct 2, 2014
aa225d7
REV Removed spacing and changed password
maxhq Oct 2, 2014
1d23e1d
REV Rearranged some code
maxhq Oct 2, 2014
b9578ab
REV Removed two spaces in output of get-table-list.pl
maxhq Oct 2, 2014
8e2bbcb
DOC Updated README.txt
maxhq Oct 2, 2014
c2d92ca
DOC Updated README (reference to Github wiki)
maxhq Oct 2, 2014
08bc7e3
DOC +"MySQL"
maxhq Oct 2, 2014
a41feda
DOC Added ".0" to version number in script
maxhq Oct 2, 2014
9b11a37
NEW Parsing of commandline arguments implemented
maxhq Jan 27, 2015
139e036
REV Stop if database password is wrong
maxhq Jan 27, 2015
cf69f01
ENH Try reverse lookup of IPs and include hostname/IP in filename
maxhq Jan 27, 2015
7e88095
REV Renamed script to zabbix-mysql-dump
maxhq Jan 27, 2015
9614a42
Bash-related fixes.
Apr 7, 2015
0994f72
CHG Merge branch 'chevah-master' (pull request #4)
maxhq Jan 22, 2016
edc19d5
CHG Default output directory is now $PWD instead of script dir
maxhq Jan 22, 2016
cb68998
ENH Add quiet mode. IP reverse lookup optional.
dschneller Mar 12, 2015
d269565
DOC Refreshed and corrected some docs and formatting
maxhq Jan 22, 2016
1df2b0c
FIX Only invoke `dig` if available
maxhq Jan 22, 2016
ae54936
ENH Add database version to filename if available
maxhq Jan 22, 2016
026ada3
ENH Option -r to rotate backup files (by Daniel Schneller)
maxhq Jan 22, 2016
1feed59
ENH Option -c to use a MySQL config ("options") file
maxhq Jan 22, 2016
cbb6161
DOC Added hint not to modify default variable values
maxhq Jan 22, 2016
0a8bc9e
FIX Fixed typo "my" --> "mysql"
maxhq Jan 22, 2016
91f655c
DOC Reformatted help page and adjusted examples
maxhq Jan 22, 2016
a337a23
FIX Reading database name from config file did not work
maxhq Jan 22, 2016
6168774
DOC Changed version number to 0.8.0
maxhq Jan 22, 2016
fb816b9
Fixes issue when stderr output is included in backup file name, e.g. …
Mar 23, 2016
fef1c40
Merge pull request #5 from nikit0z/master
maxhq Mar 24, 2016
8226d44
NEW Added MIT license
maxhq Mar 26, 2016
4be030e
DOC Mention license in script
maxhq Mar 26, 2016
4ab9f54
Change versions 2.4.0 -> 3.0.0 in tables list
ruslan-ohitin Jul 1, 2016
64f245f
Add Zabbix 3.0.x tables to the list
ruslan-ohitin Jul 1, 2016
8acf579
Change version in README
ruslan-ohitin Jul 1, 2016
123bc77
CHG Updated table versions (3.0.3 and also 2.x versions)
maxhq Jul 11, 2016
a8e71ab
DOC Set latest version to 3.0.3
maxhq Jul 11, 2016
e0d796f
Merge branch 'patch-ruslan-ohitin'
maxhq Jul 11, 2016
dd09ae2
DOC How to release a new version
maxhq Jul 11, 2016
97b4075
DOC Added link to Zabbix.org page
maxhq Jul 11, 2016
9273643
Add -x flag for xz support
jonathanspw Jul 28, 2016
5d77734
NEW: Option -x to use XZ instead of GZ for compression
jonathanspw Jul 28, 2016
89d469f
Merge remote-tracking branch 'origin/master'
jonathanspw Jul 28, 2016
c0b8b26
FIX warning: here-document at line 206 delimited by end-of-file (want…
Sep 7, 2016
962e6a4
Merge pull request #8 from msjmeyer/master
maxhq Sep 8, 2016
4659367
REV Renamed readme file and moved history into readme
maxhq Sep 8, 2016
a7a4f95
FIX Prevent "Warning: Using a password on the command line interface …
maxhq Sep 8, 2016
273bdcd
Merge branch 'master' of https://github.com/neonardo1/zabbix-backup i…
maxhq Sep 8, 2016
0f5485c
ENH Added option -0 for "no compression" and revised code for xz comp…
maxhq Sep 8, 2016
f0db84f
Merge branch 'xz-support'
maxhq Sep 8, 2016
a485284
DOC Updated readme with changes in 0.8.2
maxhq Sep 8, 2016
cc01e7b
DOC Added "Jonathan Wright" as contributor
maxhq Sep 8, 2016
22f7eda
DOC Changed some wording in readme
maxhq Sep 8, 2016
273e73e
DOC Reference latest relase in README
maxhq Sep 10, 2016
658982e
DOC Added "announcment" to RELEASE task list
maxhq Sep 10, 2016
0096543
Enhanced known working version range to 3.0.7 (thanks, Lars Vinder)
maxhq Mar 1, 2017
a8faf47
Merge branch 'master' of github.com:maxhq/zabbix-backup
maxhq Mar 1, 2017
b16b2d5
Add postgres dump
sergeygalkin Mar 3, 2017
aec57ee
Add db port option
sergeygalkin Mar 5, 2017
f0564a0
support sockets and server config parsing
gergnz Mar 15, 2017
0d53668
fix dig if host isn't set, and force options to be used over config file
gergnz Mar 15, 2017
ae46152
fig logic
gergnz Mar 15, 2017
7bc26b9
make it a bit safer
gergnz Jul 2, 2017
fd4a304
cleanup and a couple of fixes
gergnz Jul 2, 2017
5e4c034
added support up to Zabbix 4.0.0
Oct 18, 2018
2887051
Show default path to zabbix_server.conf in help output
maxhq Mar 13, 2019
bab8708
Remove unneccessary variable
maxhq Mar 13, 2019
57c028d
Merge branch 'gergnz-master'
maxhq Mar 13, 2019
93806e6
Treat "maintenance_tag" as a config table
maxhq Mar 13, 2019
2b9506d
Adjust help texts and code formatting
maxhq Mar 14, 2019
576bc9d
Merge branch 'wschaft-master' into new
maxhq Mar 15, 2019
0918db7
Rename script to prepare merge of sergeygalkin's PR
maxhq Mar 14, 2019
a59b71a
Merge branch 'sergeygalkin-master' into new
maxhq Mar 15, 2019
97fa223
Replace tabs with spaces
maxhq Mar 14, 2019
f01e1d6
Change host option to "-H" and use "-h" and "--help" to show help
maxhq Mar 14, 2019
08ada33
Change some output text
maxhq Mar 14, 2019
0a30b61
Re-add accidentially deleted help for option "-z"
maxhq Mar 14, 2019
e6c0b3d
Rename flag DATA to SCHEMAONLY to make it more clear what it means
maxhq Mar 13, 2019
360e574
Reorder options for getopts command
maxhq Mar 14, 2019
c066c10
Also read database port from Zabbix config if available
maxhq Mar 14, 2019
44a2888
Support socket connections for PostgreSQL
maxhq Mar 14, 2019
fd2c1f7
Use "which" instead of hard coded path for binaries: suggested by yangqi
maxhq Mar 15, 2019
3ed7268
Update README and script with changes an contributors
maxhq Mar 15, 2019
748e766
New option -Z to skip reading the Zabbix server config file
maxhq Mar 15, 2019
d4f19ba
Rename some variables
maxhq Mar 15, 2019
7b207e7
Re-add accidentially deleted option "-t" (merge hell...)
maxhq Mar 15, 2019
3900056
Mimic special treatment of DBHost in zabbix_serverd.conf
maxhq Mar 15, 2019
b41330d
Only output config options that are set
maxhq Mar 15, 2019
5582142
Fix handling of MySQL option file: --defaults-extra-file must come first
maxhq Mar 15, 2019
de7d90a
Don't read Zabbix config or set defaults if MySQL options file was given
maxhq Mar 15, 2019
323937b
Don't set host from Zabbix config file if socket was specified manually
maxhq Mar 15, 2019
13de513
Show help about help options (not sure if this is useful)
maxhq Mar 15, 2019
6a0df23
Update texts to be posted (LinkedIn, XING) after a release
maxhq Mar 15, 2019
dfef0ca
missing $DBHOST to mysql client - error Cant connect to local MySQL s…
tiago-cruz-movile Mar 20, 2019
7a1f5c1
moved $DBHOST to psql case
tiago-cruz-movile Mar 21, 2019
a9ddde2
Merge branch 'tiago-cruz-movile-master'
maxhq Mar 21, 2019
2d38d33
Bump version number and add release info
maxhq Mar 21, 2019
bfb962e
Change title
maxhq Mar 21, 2019
8e8ce88
Update release instructions
maxhq Mar 21, 2019
1eff0a9
Add license scan report and status
fossabot Jul 12, 2019
1a35479
Fix shellcheck SC2236: Use -n instead of ! -z.
mjtrangoni Aug 9, 2019
9bd379c
Fix shellcheck SC2162: read without -r will mangle backslashes
mjtrangoni Aug 9, 2019
c52320c
Escape special characters while reading password
ironbishop Sep 17, 2019
0d79386
Don't source (PHP) Zabbix config to prevent possible escaping issues
maxhq Jan 16, 2020
c6e7d93
Fix accidentally disabled cleanup of postgresql password file
maxhq Jan 16, 2020
c2aaf2f
Merge branch 'fix-shellcheck-issues' of https://github.com/mjtrangoni…
maxhq Jan 16, 2020
a1ea57e
Merge branch 'mjtrangoni-fix-shellcheck-issues' into next
maxhq Jan 16, 2020
402503e
Merge pull request #17 from fossabot/master
maxhq Jan 16, 2020
c592a3a
Revert "Add license scan report and status"
maxhq Jan 16, 2020
ee6a2f8
Fix get-table-list.pl to work with Git repository
maxhq Jan 16, 2020
9d093de
get-table-list.pl: merge zabbix-dump's existing table config into output
maxhq Jan 16, 2020
c992748
get-table-list.pl: move some code into subroutines
maxhq Jan 16, 2020
3210328
Update table list to Zabbix 4.4.4
maxhq Jan 16, 2020
805b50f
Merge branch 'next'
maxhq Jan 16, 2020
27a105e
Set hostname to `uname -n` if DB is on localhost
maxhq Jan 16, 2020
2b325d5
Bump version number to 0.9.2 and update docs
maxhq Jan 16, 2020
b5464e5
Update release docs
maxhq Jan 16, 2020
b3c3355
Check for unknown tables; make PostgreSQL dump more stable
maxhq Jan 17, 2020
d5d5f97
Replace --extended-insert=FALSE with equivalent --skip-extended-insert
maxhq Jan 17, 2020
fc1896b
Rename misleading variable DATA_TABLES to SCHEMAONLY_TABLES
maxhq Jan 17, 2020
7b6616e
Do not backup each MySQL table individually anymore
maxhq Jan 17, 2020
815c211
Process 'DBSchema' option in Zabbix config and add -S to specify schema
maxhq Jan 17, 2020
2326371
Also output error message for unknown tables in quiet mode
maxhq Jan 17, 2020
6eed145
Get rid of "echo -e" in favor of "echo $''"
maxhq Jan 17, 2020
c2971ab
Skip IP reverse lookup for localhost, fix multiline dig answers
maxhq Jan 17, 2020
fa9332e
New option -v (--version) to show version information
maxhq Jan 17, 2020
4a093d3
Bump version to 0.9.3 and update changelog
maxhq Jan 17, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix handling of MySQL option file: --defaults-extra-file must come first
maxhq committed Mar 15, 2019
commit 5582142f680a88c946f414822faf7e6ffa3b2613
3 changes: 2 additions & 1 deletion zabbix-dump
Original file line number Diff line number Diff line change
@@ -260,7 +260,6 @@ fi
SUFFIX=""; test ! -z $COMPRESSION && SUFFIX=".${COMPRESSION}"

DB_OPTS=()
[ ! -z "$DBHOST" ] && DB_OPTS=("${DB_OPTS[@]}" -h $DBHOST)
case $DBTYPE in
mysql)
[ ! -z "$MYSQL_CONFIG" ] && DB_OPTS=("${DB_OPTS[@]}" --defaults-extra-file="$MYSQL_CONFIG")
@@ -284,6 +283,8 @@ case $DBTYPE in
[ ! -z "$DBNAME" ] && DB_OPTS_BATCH=("${DB_OPTS_BATCH[@]}" -d $DBNAME)
;;
esac
[ ! -z "$DBHOST" ] && DB_OPTS=("${DB_OPTS[@]}" -h $DBHOST)

# Log file for errors
ERRORLOG=$(mktemp)