Comment 8 for bug 1093385

Revision history for this message
Raghavendra D Prabhu (raghavendra-prabhu) wrote :

It won't harm if InnoDB is doing O_DIRECT only I/O but innodb_flush_method is set otherwise, it can.

Also, if/when PXB is running in O_DIRECT mode, it will not, unlike rsync, dirty any pages in page cache, so that shouldn't apply here. (and log file pages when ALL_O_DIRECT, otherwise only data pages).

I also ran a quick test
===============================================

dd if=/dev/urandom of=file1 bs=1M count=200
200+0 records in
200+0 records out
209715200 bytes (210 MB) copied, 19.8979 s, 10.5 MB/s
dd if=/dev/urandom of=file1 bs=1M count=200 0.00s user 19.86s system 99% cpu 19.928 total

linux-fadvise file1 POSIX_FADV_SEQUENTIAL
Going to fadvise file1 as mode POSIX_FADV_SEQUENTIAL
offset: 0
length: 209715200
mode: POSIX_FADV_SEQUENTIAL
WIN

linux-fincore -s file1
filename size total_pages min_cached page cached_pages cached_size cached_perc
-------- ---- ----------- --------------- ------------ ----------- -----------
file1 209715200 51200 -1 0 0 0.00
---
total cached size: 0

cat file1 >/dev/null

linux-fincore -s file1
filename size total_pages min_cached page cached_pages cached_size cached_perc
-------- ---- ----------- --------------- ------------ ----------- -----------
file1 209715200 51200 0 51200 209715200 100.00
---

linux-fadvise file1 POSIX_FADV_DONTNEED
Going to fadvise file1 as mode POSIX_FADV_DONTNEED
offset: 0
length: 209715200
mode: POSIX_FADV_DONTNEED
WIN

linux-fincore -s file1
filename size total_pages min_cached page cached_pages cached_size cached_perc
-------- ---- ----------- --------------- ------------ ----------- -----------
file1 209715200 51200 -1 0 0 0.00
---
total cached size: 0