Merge "Additional logs for Mariadb restore strategy"

This commit is contained in:
Zuul 2019-04-05 22:59:29 +00:00 committed by Gerrit Code Review
commit ecf8a78ef9
1 changed files with 6 additions and 4 deletions

View File

@ -85,10 +85,12 @@ class MySQLRestoreMixin(object):
run_as_root=True, root_helper="sudo")
utils.execute("chown", "mysql:mysql", run_dir, err_log_file.name,
init_file.name, run_as_root=True, root_helper="sudo")
child = pexpect.spawn(
"sudo mysqld_safe --init-file=%s --log-error=%s" %
(init_file.name, err_log_file.name))
command_mysql_safe = ("sudo mysqld_safe"
" --init-file=%s"
" --log-error=%s" %
(init_file.name, err_log_file.name))
LOG.debug("Spawning: %s" % command_mysql_safe)
child = pexpect.spawn(command_mysql_safe)
try:
index = child.expect(['Starting mysqld daemon'])
if index == 0: