1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-7046: MySQL#74480 - Failing assertion: os_file_status(newpath, &exists, &type)

after Operating system error number 36 in a file operation.

Analysis: os_file_get_status did not handle error ENAMETOOLONG
correctly.

Fix: Add correct handling for error ENAMETOOLONG. Note that on InnoDB
case the error is not passed all the way up to server. That would
be bigger rewamp.
This commit is contained in:
Jan Lindström
2014-11-25 11:38:01 +02:00
parent b62c4c6586
commit f3bdf9d741
6 changed files with 67 additions and 4 deletions

View File

@ -0,0 +1,31 @@
--source include/have_innodb.inc
--source include/have_partition.inc
# Ignore OS errors
call mtr.add_suppression("InnoDB: File ./test/t1*");
call mtr.add_suppression("nnoDB: Error number*");
# MDEV-7046: MySQL#74480 - Failing assertion: os_file_status(newpath, &exists, &type)
# after Operating system error number 36 in a file operation
USE test;
create table t1(f1 INT,f2 INT,f3 CHAR (10),primary key(f1,f2)) partition by range(f1) subpartition by hash(f2) subpartitions 2 (partition p1 values less than (0),partition p2 values less than (2),partition p3 values less than (2147483647));
--replace_regex /'.*t2_new.*'/'t2_new'/
--error 7
RENAME TABLE t1 TO `t2_new..............................................end`;
alter table t1 engine=innodb;
--replace_regex /'.*t2_new.*'/'t2_new'/
--error 1025
RENAME TABLE t1 TO `t2_new..............................................end`;
--replace_regex /'.*t2_new.*'/'t2_new'/
show warnings;
drop table t1;
DROP DATABASE test;CREATE DATABASE test;USE test;
SET @@session.storage_engine=MYISAM;
--error 1
CREATE TABLE t1(id INT,purchased DATE)PARTITION BY RANGE(YEAR(purchased)) SUBPARTITION BY HASH(TO_DAYS(purchased)) SUBPARTITIONS 2 (PARTITION p0 VALUES LESS THAN MAXVALUE (SUBPARTITION sp0 DATA DIRECTORY='/tmp/not-existing' INDEX DIRECTORY='/tmp/not-existing',SUBPARTITION sp1));
CREATE TABLE t1(id INT,purchased DATE)PARTITION BY RANGE(YEAR(purchased)) SUBPARTITION BY HASH(TO_DAYS(purchased)) SUBPARTITIONS 2 (PARTITION p0 VALUES LESS THAN MAXVALUE (SUBPARTITION sp0,SUBPARTITION sp1));
ALTER TABLE t1 ENGINE=InnoDB;
drop table t1;