[MDEV-33373] Unexpected ER_FILE_NOT_FOUND upon reading from logging table after crash recovery Created: 2024-02-02  Updated: 2024-02-02

Status: Open
Project: MariaDB Server
Component/s: Server
Affects Version/s: 10.4, 10.5, 10.6, 10.11, 11.0, 11.1, 11.2, 11.3, 11.4
Fix Version/s: 10.5, 10.6, 10.11, 11.0, 11.1, 11.2, 11.3

Type: Bug Priority: Minor
Reporter: Elena Stepanova Assignee: Oleksandr Byelkin
Resolution: Unresolved Votes: 0
Labels: None


 Description   

SET GLOBAL log_output="TABLE";
CREATE TABLE t (a INT);
--let $shutdown_timeout= 0
--source include/restart_mysqld.inc
DROP TABLE t;
SELECT * FROM mysql.general_log;

10.5 cc5c0eda4c1a516753de238e02a024b0f044b738

mysqltest: At line 6: query 'SELECT * FROM mysql.general_log' failed: 1017: Can't find file: './mysql/general_log.CSV' (errno: 2 "No such file or directory")

The table is of course still there and is readable after REPAIR.

With some other combinations of queries and startup options different errors can be produced, ranging between more or less expected, such as "Got error 175 "File too short; Expected more data in file" from storage engine CSV", to confusing ones like "Cannot execute statement in a READ ONLY transaction" if the server is running under tx-read-only. I'm not sure whether they all have the same root cause (other than the expected table corruption upon a crash in the absence of automatic recovery), or they would need to be dealt with separately. So far I'll file the one above, as it is the strangest from those I've seen so far.


Generated at Thu Feb 08 10:38:25 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.