Linux I/O tuning: CFQ vs. deadline

From: Greg Smith <greg(at)2ndquadrant(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Linux I/O tuning: CFQ vs. deadline
Date: 2010-02-08 09:45:10
Message-ID: 4B6FDD26.9010106@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Recently I've made a number of unsubstantiated claims that the deadline
scheduler on Linux does bad things compared to CFQ when running
real-world mixed I/O database tests. Unfortunately every time I do one
of these I end up unable to release the results due to client
confidentiality issues. However, I do keep an eye out for people who
run into the same issues in public benchmarks, and I just found one:
http://insights.oetiker.ch/linux/fsopbench/

The problem analyzed in the "Deadline considered harmful" section looks
exactly like what I run into: deadline just does some bad things when
the I/O workload gets complicated. And the conclusion reached there,
"the deadline scheduler did not have advantages in any of our test
cases", has been my conclusion for every round of pgbench-based testing
I've done too. In that case, the specific issue is that reads get
blocked badly when checkpoint writes are doing heavier work; you can see
the read I/O numbers reported by "vmstat 1" go completely to zero for a
second or more when it happens. That can happen with CFQ, too, but it
consistently seems more likely to occur with deadline.

--
Greg Smith 2ndQuadrant Baltimore, MD
PostgreSQL Training, Services and Support
greg(at)2ndQuadrant(dot)com www.2ndQuadrant.com

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Albe Laurenz 2010-02-08 14:57:25 Re: Linux I/O tuning: CFQ vs. deadline
Previous Message Albe Laurenz 2010-02-08 08:57:14 Re: foreign key constraint lock behavour in postgresql