fail when os_file_set_nocache fails
Bug #801989 reported by
Mark Callaghan
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS | Status tracked in 5.7 | |||||
5.1 |
Won't Fix
|
Medium
|
Unassigned | |||
5.5 |
Fix Released
|
Medium
|
Nickolay Ihalainen | |||
5.6 |
Fix Released
|
Medium
|
Nickolay Ihalainen | |||
5.7 |
Fix Released
|
Medium
|
Nickolay Ihalainen |
Bug Description
With innodb_flush_method == ALL_O_DIRECT or O_DIRECT, os_file_set_nocache is called after the file has been opened to put the fd in direct IO mode. os_file_set_nocache logs an error but does not return an error on failure. XtraDB appears to not call fsync when the innodb_
Related branches
lp:~vlad-lesin/percona-server/5.5-bug801989
On hold
for merging
into
lp:percona-server/5.5
- Alexey Kopytov (community): Needs Fixing
-
Diff: 64 lines (+13/-5)2 files modifiedPercona-Server/storage/innobase/include/os0file.h (+3/-2)
Percona-Server/storage/innobase/os/os0file.c (+10/-3)
lp:~vlad-lesin/percona-server/5.1-bug801989
On hold
for merging
into
lp:percona-server/5.1
- Alexey Kopytov (community): Needs Fixing
-
Diff: 64 lines (+13/-5)2 files modifiedPercona-Server/storage/innodb_plugin/include/os0file.h (+3/-2)
Percona-Server/storage/innodb_plugin/os/os0file.c (+10/-3)
Changed in percona-server: | |
assignee: | nobody → Yasufumi Kinoshita (yasufumi-kinoshita) |
Changed in percona-server: | |
assignee: | Yasufumi Kinoshita (yasufumi-kinoshita) → nobody |
Changed in percona-server: | |
assignee: | nobody → Vladislav Lesin (vlad-lesin) |
tags: | added: xtradb |
To post a comment you must log in.
if O_DIRECT is set, InnoDB tries to use TABLESPACE files in O_DIRECT. file_flush_ method != SRV_UNIX_NOSYNC) { file_spaces( FIL_TABLESPACE) ;
And in log_checkpoint(),
if (srv_unix_
fil_flush_
}
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( ) ?
============== file_flush_ method == SRV_UNIX_ ALL_O_DIRECT) {
srv_unix_ file_flush_ method = SRV_UNIX_O_DIRECT;
if (srv_unix_
}
==============