summaryrefslogtreecommitdiffstats
path: root/mysql-test/main/flush_logs_not_windows.test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/main/flush_logs_not_windows.test')
-rw-r--r--mysql-test/main/flush_logs_not_windows.test19
1 files changed, 19 insertions, 0 deletions
diff --git a/mysql-test/main/flush_logs_not_windows.test b/mysql-test/main/flush_logs_not_windows.test
new file mode 100644
index 00000000..f4eaa2fa
--- /dev/null
+++ b/mysql-test/main/flush_logs_not_windows.test
@@ -0,0 +1,19 @@
+# Tests will be skipped for the view protocol because the view protocol creates
+# an additional util connection and other statistics data
+-- source include/no_view_protocol.inc
+
+source include/not_windows.inc;
+source include/not_embedded.inc;
+source include/not_as_root.inc;
+
+#
+# MDEV-17710 "unknown error" with FLUSH LOGS if log directory is not writeable
+#
+move_file $MYSQLTEST_VARDIR/log/mysqld.1.err $MYSQLTEST_VARDIR/log/mysqld.1.err-bak;
+system chmod u-w $MYSQLTEST_VARDIR/log;
+replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR;
+error ER_CANT_CREATE_FILE;
+flush logs;
+system chmod u+w $MYSQLTEST_VARDIR/log;
+move_file $MYSQLTEST_VARDIR/log/mysqld.1.err-bak $MYSQLTEST_VARDIR/log/mysqld.1.err;
+flush logs;