[Maria-developers] Random test failure in main.show_check in mariadb 5.1 tree

2009-05-25 Thread Kristian Nielsen
There is another test failure visible in Buildbot:


https://askmonty.org/buildbot/builders/gentoo-x86-dbg/builds/13/steps/test/logs/stdio

---
main.show_check  [ fail ]
Test ended at 2009-05-22 11:47:11

CURRENT_TEST: main.show_check
--- 
/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/r/show_check.result
 2009-05-22 09:56:56.0 +0300
+++ 
/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/r/show_check.reject
 2009-05-22 10:47:11.0 +0300
@@ -252,13 +252,13 @@
 flush tables;
 show open tables;
 Database   Table   In_use  Name_locked
-mysql  general_log 0   0
+mysql  general_log 1   0
 create table t1(n int);
 insert into t1 values (1);
 show open tables;
 Database   Table   In_use  Name_locked
-test   t1  0   0
 mysql  general_log 0   0
+test   t1  0   0
 drop table t1;
 create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 
CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 
DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
 show create table t1;

mysqltest: Result content mismatch

 - saving 
'/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/var/log/main.show_check/'
 to 
'/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/var/log/main.show_check/'

Retrying test, attempt(2/3)...

main.show_check  [ retry-pass ]   1421

Retrying test, attempt(3/3)...

main.show_check  [ retry-pass ]   1451
---

As can be seen, it is a random failure.

Would be really great if someone could take a look and fix this.

 - Kristian.

___
Mailing list: https://launchpad.net/~maria-developers
Post to : maria-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~maria-developers
More help   : https://help.launchpad.net/ListHelp


Re: [Maria-developers] Random test failure in main.show_check in mariadb 5.1 tree

2009-06-07 Thread Michael Widenius

Hi!

> "Kristian" == Kristian Nielsen  writes:

Kristian> There is another test failure visible in Buildbot:
Kristian> 
https://askmonty.org/buildbot/builders/gentoo-x86-dbg/builds/13/steps/test/logs/stdio

Kristian> 
---
Kristian> main.show_check  [ fail ]
Kristian> Test ended at 2009-05-22 11:47:11

Kristian> CURRENT_TEST: main.show_check
Kristian> --- 
/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/r/show_check.result
   2009-05-22 09:56:56.0 +0300
Kristian> +++ 
/home/buildbot/maria-slave/psergey-foxhole-x86/build/mysql-test/r/show_check.reject
   2009-05-22 10:47:11.0 +0300
Kristian> @@ -252,13 +252,13 @@
Kristian>  flush tables;
Kristian>  show open tables;
Kristian>  Database Table   In_use  Name_locked
Kristian> -mysqlgeneral_log 0   0
Kristian> +mysqlgeneral_log 1   0
Kristian>  create table t1(n int);
Kristian>  insert into t1 values (1);
Kristian>  show open tables;
Kristian>  Database Table   In_use  Name_locked
Kristian> -test t1  0   0
Kristian>  mysqlgeneral_log 0   0
Kristian> +test t1  0   0
Kristian>  drop table t1;
Kristian>  create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) 
AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 
MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
Kristian>  show create table t1;



Kristian> As can be seen, it is a random failure.

Kristian> Would be really great if someone could take a look and fix this.

first problem:

Have no clue how the general_log could say its in use.
This comes from table->in_use, which should be 0 if the table
is not in use by another thread.

I spend some time looking at this, and in_use should be reset by
previous statement in close_thread_tables().

If this happens again, we should file a bug report to MySQL;  If they
are not fixing this, I will take a look.

Second problem:

Don't know if it's defined in which order the tables are in 'show open
table' so the second test is bogus. (In theory it should be a defined
order based on hash values, but apparently it isn't)

I think we should change the code to use:

show open tables from test

Which should fix it.

I noticed that in 5.1 they have 'fixed' this by removing a lot of
SHOW OPEN TABLES test, which I think is the wrong fix.  What they should have
instead done would be to add a --sort-result line to mysqltest.c

Regards,
Monty

___
Mailing list: https://launchpad.net/~maria-developers
Post to : maria-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~maria-developers
More help   : https://help.launchpad.net/ListHelp