Hi, On Sat, 20 Aug 2011, huang jun wrote: > 2011/8/20 Sage Weil <sage@xxxxxxxxxxxx>: > > On Sat, 20 Aug 2011, huang jun wrote: > >> hi,all > >> Recently,we have a test to compare async i/o and sync i/o in OSD. > >> The osd jounral was written in sync + direct io mode now, that heavily > >> infuluenced the write performance. > >> we use linux aio API. test file size is 40MB,and disk isn't busy. > >> here is the test result: > >> type ext3 > >> sync write+direct io 4.441s > >> > >> async write +direct io 0.462s > >> > >> we are glad to see that, so we want to affirm that : > >> 1) can we use async+direct io to achieve better write performance if > >> we used osd journal? > > > > Do you mean changing the writes in os/FileJournal.cc to be async? As long > > as the journal does not acknowledge a write until it is stable on disk, > > that is fine. Async IO would be a nice improvement here; I think > > currently it's a single sync O_DIRECT io in flight at a time. > yes, we'd like to change FileJournal.cc to async. > > The test is to write a 40MB file via which interface? Via a kernel client > > mount? > At persent, we just separately tested the async io,and found that > would be useful. > now, we are doing the work to add async code in filejournal.cc, and it > should be finished next week. and then we'll have a test. Have you had any luck with this? This is definitely a change we'd like to make. We suspect the sync journal writes are hurting latency under a lot of workloads. sage