Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1UplEc-00009f-A7 for pgsql-performance@arkaria.postgresql.org; Thu, 20 Jun 2013 20:13:34 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1UplEb-0007kN-Le for pgsql-performance@arkaria.postgresql.org; Thu, 20 Jun 2013 20:13:33 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1UplEZ-0007k8-EE for pgsql-performance@postgresql.org; Thu, 20 Jun 2013 20:13:31 +0000 Received: from smtp.optionshouse.com ([38.98.137.6] helo=smtp.peak6.com) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1UplEI-0000Pc-5Y for pgsql-performance@postgresql.org; Thu, 20 Jun 2013 20:13:16 +0000 X-AuditID: 0a64cb20-b7f1f6d000004114-49-51c36256b756 Message-ID: <51C36256.6040502@optionshouse.com> Date: Thu, 20 Jun 2013 15:13:10 -0500 From: Shaun Thomas Reply-To: Organization: Peak6 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130510 Thunderbird/17.0.6 MIME-Version: 1.0 To: CS DBA CC: Subject: Re: PostgreSQL settings for running on an SSD drive References: <51C35E6C.1090705@consistentstate.com> In-Reply-To: <51C35E6C.1090705@consistentstate.com> Content-Type: text/plain; charset="UTF-8"; format=flowed content-transfer-encoding: 8bit X-Originating-IP: [10.10.201.64] X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrKIsWRmVeSWpSXmKPExsXClcIroRuWdDjQ4PQ8dYtFi/YwW1yfeY7Z gcnjz42X7B4X9k1jD2CKamC0SczLyy9JLElVSEktTrZV8i8oyczPK/bILy1OVXDJLE7OSczM TS1SUshMsVUyVlIoyElMTs1NzSuxVUosKEjNS1Gy41LAADZAZZl5Cql5yfkpmXnptkqewf66 FhamlrqGSnbxyCChkyXj+av/zAWt/BWTZ9xjbmBs4eli5OSQEDCRaFn+hRHCFpO4cG89G4jN K6AvcX7nfqYuRg4OFgFVie+PWEHCbAK6EpP6V4CVCAmoSPSdvcEEYvMLCEvs+9DEDGKLCoRJ vF82lRVijKDEyZlPWEBsEQF1ib89N8FWMQuoScx9OAmsRljATWLj/A/MEDONJG7/awCLcwoY Syy51MgGUW8hsfjNQXYIW16ieetsqHpViRXNE9kgzleQ+H/lHdMERqFZSFbPQtI+C0n7Akbm VYzixWWJyRmZpgXFuSUFRnoFqYnZZnp5qSWbGMFxe1phB+P3TqtDjAIcjEo8vAKmhwOFWBPL iitzDzFKcDArifA+CgYK8aYkVlalFuXHF5XmpBYfYvQBBtlEZinR5HxgSskriTc0NjUwtTQ1 NDU3NTTCIawkzruPaVmgkEA6MJFkp6YWpBbBjGPi4JRqYLR8ULJkb2kbL++/2Pg3/PeF7gVZ r1KRPHaQ0/Rhcv7mSWefmW7cevR0xaOLK9bv/tUQdbjwqFVnLnPXbEkbhjiNxp6O+9dilb5N /7CQ71eaqV78GxY/V3P/NP45D3ojmmT3m652f8w6kyNnTodG5b8Xn5NLQ+ZGikw8YRcxieVE zI6jH+T+b1ZiKc5INNRiLipOBAA11zGcCAMAAA== X-Pg-Spam-Score: -0.5 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-performance Precedence: bulk Sender: pgsql-performance-owner@postgresql.org On 06/20/2013 02:56 PM, CS DBA wrote: > They have a PostgreSQL setup guide from Fusion recommending the > following settings: > effective_io_concurrency=0 > bgwriter_lru_maxpages=0 > random_page_cost=0.1 > sequential_page_cost=0.1
 Well, since FusionIO drives have a limited write cycle (5PB?), I can somewhat see why they would recommend turning off the background writer. We were a bit more conservative in our settings, though: seq_page_cost = 1.0 # Default random_page_cost = 1.0 # Reduce to match seq_page_cost Yep. That's it. Just the one setting. FusionIO drives are fast, but they're not infinitely fast. My tests (and others) show they're about 1/2 the speed of memory, regarding IOPS. And while they can serve very aggressive sequential reads, they're not orders of magnitude faster than spindles in anything but IOPS. Knowing that, we reduced random page fetches to be the same speed as sequential page fetches. This has served our heavy OLTP system (and its FusionIO underpinnings) very well so far. But like I said, these are pretty conservative. I'd start at 1 and reduce in 0.2 increments and run tests to see if there's a beneficial change. If it helps, here's our system stats, some only relevant during financial hours: * A billion queries per day * Sustained 500+ write queries per second * Average 7000-ish transactions per second. * Average 35,000-ish queries per second. * pg_xlog and pgdata on same FusionIO device * 2 years, 3 months in operation * 1.29PB written * 1.75PB read The load on our system right now is 3.7 on a 24 CPU box while serving 4100 TPS after active trading hours. The FusionIO drive is basically the only reason we can do all of that without a lot of excessive contortions. -- Shaun Thomas OptionsHouse | 141 W. Jackson Blvd. | Suite 500 | Chicago IL, 60604 312-676-8870 sthomas@optionshouse.com ______________________________________________ See http://www.peak6.com/email_disclaimer/ for terms and conditions related to this email -- Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance