Skip to content

Commit f7f2dee

Browse files
committed
variants/scale-1/ starts without writing a grastate.dat
1 parent 3aa381a commit f7f2dee

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

base-defaultconfig/init.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ function wsrepRecover {
2525
}
2626

2727
function wsrepForceBootstrap {
28-
sed -i 's|safe_to_bootstrap: 0|safe_to_bootstrap: 1|' /data/db/grastate.dat
28+
sed -i 's|safe_to_bootstrap: 0|safe_to_bootstrap: 1|' /data/db/grastate.dat \
29+
|| [ ! -f /data/db/grastate.dat ] && echo 'Patch failed due to no /data/db/grastate.dat, might not need to force bootstrap'
2930
}
3031

3132
[[ $STATEFULSET_SERVICE = mariadb.* ]] || echo "WARNING: unexpected service name $STATEFULSET_SERVICE, Peer detection below may fail falsely."

0 commit comments

Comments
 (0)