This repository was archived by the owner on Oct 29, 2023. It is now read-only.
File tree 3 files changed +20
-3
lines changed
3 files changed +20
-3
lines changed Original file line number Diff line number Diff line change
1
+ ## 1.71.0 11-Dec-2022
2
+
3
+ ## ADJUSTMENTS
4
+
5
+ * Update code of ` show_binlog ` script to find the right binary log
6
+ with version 8.0.x, when used without ` --master ` outside replication.
7
+
8
+
1
9
## 1.70.0 31-Oct-2022
2
10
3
11
## NEW FEATURES
Original file line number Diff line number Diff line change 1
- 1.70 .0
1
+ 1.71 .0
Original file line number Diff line number Diff line change 13
13
exit 1
14
14
fi
15
15
16
+ base='mysql-bin'
17
+ if [ "$MYSQL_VERSION_MAJOR" == "8" ]
18
+ then
19
+ if [ -f ./data/binlog.index ]
20
+ then
21
+ base="binlog"
22
+ fi
23
+ fi
24
+
16
25
pattern=$1
17
26
[ -z "$pattern" ] && pattern='[0-9]*'
18
27
function get_help {
19
28
exit_code=$1
20
29
[ -z "$exit_code" ] && exit_code=0
21
30
echo "# Usage: $0 [BINLOG_PATTERN] "
22
- echo "# Where BINLOG_PATTERN is a number, or part of a number used after 'mysql-bin '"
31
+ echo "# Where BINLOG_PATTERN is a number, or part of a number used after '${base} '"
23
32
echo "# (The default is '[0-9]*]')"
24
33
echo "# examples:"
25
34
echo "# ./show_binlog 000001 | less "
33
42
get_help 0
34
43
fi
35
44
# set -x
36
- last_binlog=$(ls -lotr data/mysql-bin.$ pattern | tail -n 1 | awk '{print $NF}')
45
+ last_binlog=$(ls -lotr data/${base}.${ pattern} | tail -n 1 | awk '{print $NF}')
37
46
38
47
if [ -z "$last_binlog" ]
39
48
then
You can’t perform that action at this time.
0 commit comments