Comment 1 for bug 801989

Revision history for this message
Yasufumi Kinoshita (yasufumi-kinoshita) wrote :

if O_DIRECT is set, InnoDB tries to use TABLESPACE files in O_DIRECT.
And in log_checkpoint(),
 if (srv_unix_file_flush_method != SRV_UNIX_NOSYNC) {
  fil_flush_file_spaces(FIL_TABLESPACE);
 }
so, tablespace files seem to be flushed even if O_DIRECT is fail.

The problem seems only about ALL_O_DIRECT of XtraDB.

So, how about add following code to the fail case of os_file_set_nocache() ?

==============
if (srv_unix_file_flush_method == SRV_UNIX_ALL_O_DIRECT) {
        srv_unix_file_flush_method = SRV_UNIX_O_DIRECT;
}
==============