Skip to content

Commit e81cf2f

Browse files
committed
resolve comments
Signed-off-by: SK Ali Arman <[email protected]>
1 parent 4800809 commit e81cf2f

File tree

1 file changed

+6
-16
lines changed

1 file changed

+6
-16
lines changed

scripts/run.sh

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,6 @@ if [ -z "$whitelist" ]; then
112112
fi
113113
fi
114114

115-
innodb_buffer_pool_size="$INNODB_BUFFER_POOL_SIZE"
116-
group_replication_message_cache_size="$GROUP_REPLICATION_MESSAGE_CACHE_SIZE"
117-
118115
# the mysqld configurations have take by following
119116
# 01. official doc: https://dev.mysql.com/doc/refman/5.7/en/group-replication-configuring-instances.html
120117
# 02. digitalocean doc: https://www.digitalocean.com/community/tutorials/how-to-configure-mysql-group-replication-on-ubuntu-16-04
@@ -136,15 +133,15 @@ log_bin = binlog
136133
loose-group_replication_bootstrap_group = OFF
137134
loose-group_replication_start_on_boot = OFF
138135
139-
140136
# default tls configuration for the group
141137
# group_replication_recovery_use_ssl will be overwritten from DB arguments
142138
loose-group_replication_ssl_mode = REQUIRED
143139
loose-group_replication_recovery_use_ssl = 1
144140
145141
# recommended config
146-
innodb_buffer_pool_size = "${innodb_buffer_pool_size}"
147-
loose-group-replication-message-cache-size = "${group_replication_message_cache_size}"
142+
innodb_buffer_pool_size = "$INNODB_BUFFER_POOL_SIZE"
143+
loose-group-replication-message-cache-size = "$GROUP_REPLICATION_MESSAGE_CACHE_SIZE"
144+
binlog_expire_logs_seconds = "$BINLOG_EXPIRE_LOGS_SECONDS"
148145
149146
# Shared replication group configuration
150147
loose-group_replication_group_name = "${GROUP_NAME}"
@@ -188,8 +185,9 @@ loose-group_replication_ssl_mode = REQUIRED
188185
loose-group_replication_recovery_use_ssl = 1
189186
190187
# recommended config
191-
innodb_buffer_pool_size = "${innodb_buffer_pool_size}"
192-
loose-group-replication-message-cache-size = "${group_replication_message_cache_size}"
188+
innodb_buffer_pool_size = "$INNODB_BUFFER_POOL_SIZE"
189+
loose-group-replication-message-cache-size = "$GROUP_REPLICATION_MESSAGE_CACHE_SIZE"
190+
binlog_expire_logs_seconds = "$BINLOG_EXPIRE_LOGS_SECONDS"
193191
194192
# Shared replication group configuration
195193
loose-group_replication_group_name = "${GROUP_NAME}"
@@ -216,14 +214,6 @@ socket="/var/run/mysqld/mysqld.sock"
216214
EOL
217215
fi
218216

219-
# recommended config
220-
if [ -v BINLOG_EXPIRE_LOGS_SECONDS ]; then
221-
cat >>/etc/mysql/group-replication.conf.d/group.cnf <<EOL
222-
binlog_expire_logs_seconds = "$BINLOG_EXPIRE_LOGS_SECONDS"
223-
EOL
224-
fi
225-
226-
227217
# wait for mysql daemon be running (alive)
228218
function wait_for_mysqld_running() {
229219
local mysql="$mysql_header --host=$localhost"

0 commit comments

Comments
 (0)