Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TibeI-0006Is-Ah for pgsql-performance@arkaria.postgresql.org; Wed, 12 Dec 2012 02:02:14 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TibeH-0004wu-5O for pgsql-performance@arkaria.postgresql.org; Wed, 12 Dec 2012 02:02:13 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TibeG-0004wp-Ab for pgsql-performance@postgresql.org; Wed, 12 Dec 2012 02:02:12 +0000 Received: from outmail149080.authsmtp.com ([62.13.149.80]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TibeD-0003xl-OT for pgsql-performance@postgresql.org; Wed, 12 Dec 2012 02:02:12 +0000 Received: from mail-c233.authsmtp.com (mail-c233.authsmtp.com [62.13.128.233]) by punt10.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id qBC2271c099139; Wed, 12 Dec 2012 02:02:07 GMT Received: from ayaki.localdomain (58-7-194-83.dyn.iinet.net.au [58.7.194.83]) (authenticated bits=0) by mail.authsmtp.com (8.14.2/8.14.2/) with ESMTP id qBC220oE024477 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 12 Dec 2012 02:02:03 GMT Message-ID: <50C7E598.2070902@2ndQuadrant.com> Date: Wed, 12 Dec 2012 10:02:00 +0800 From: Craig Ringer Organization: 2nd Quadrant User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Evgeny Shishkin CC: =?windows-1252?Q?Niels_Kristian_Schj=F8dt?= , Jeff Janes , "pgsql-performance@postgresql.org" Subject: Re: Do I have a hardware or a software problem? References: <8F7661E7-D6D4-4334-8C6A-A8B6C56A2C3F@autouncle.com> <50C7351C.30407@2ndQuadrant.com> <4507A68A-3CD5-4283-AFA5-1C0593427E14@autouncle.com> <67FBF3AF-5C6A-45D4-9206-7257C8C01C5E@gmail.com> <50C7D7D2.4070605@2ndQuadrant.com> <2BCB6843-1396-42C9-A5BF-21C7C978FF4B@gmail.com> <50C7DDDE.1000000@2ndQuadrant.com> <3ADBD9A3-966F-40E8-AF78-0F2093D79BEE@gmail.com> In-Reply-To: <3ADBD9A3-966F-40E8-AF78-0F2093D79BEE@gmail.com> X-Enigmail-Version: 1.4.6 Content-Type: multipart/alternative; boundary="------------070908010903070401020607" X-Server-Quench: ed3b6b61-43ff-11e2-a49c-0025907707a1 X-AuthReport-Spam: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse X-AuthRoute: OCdxZQATClZeVg0b BQteCiN5VAwpPBRK HVkIKg5MJUcNSQVJ NksachtFaQdbaVxS HGQLWlZEUF97WWF/ aw8faA1DZVRPVgF0 WEtWQFdQERppT11z dRwcUkYHdwdCfHl3 K0RgWXdbEhEudhR7 EEhVCGkFMzF9aWFK Ul0JcwoHbQNKfBpM ald4VHRcYCtlM3Bw LDceBR4WBxBqYAhS CiBFLVsMTA4CVj41 XRwdFC8iVUofDyx7 NBsoNkEVBktZKl81 O18sXAVw X-Authentic-SMTP: 61633235383639.1021:706 X-AuthFastPath: 0 (Was 255) X-AuthSMTP-Origin: 58.7.194.83/2525 X-AuthVirus-Status: No virus detected - but ensure you scan with your own anti-virus system. X-Pg-Spam-Score: -2.6 (--) 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 This is a multi-part message in MIME format. --------------070908010903070401020607 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit On 12/12/2012 09:44 AM, Evgeny Shishkin wrote: > So far, more than a year already, i bought consumer ssds with 300-400$ > hw raid. Cost effective and fast, may be not very safe, but so far so > good. All data protection measures from postgresql are on, of course. You're aware that many low end SSDs lie to the RAID controller about having written data, right? Even if the RAID controller sends a flush command, the SSD might cache the write in non-durable cache. If you're using such SSDs and you lose power, data corruption is extremely likely, because your SSDs are essentially ignoring fsync. Your RAID controller's BBU won't save you, because once the disks tell the RAID controller the data has hit durable storage, the RAID controller feels free to flush it from its battery backed cache. If the disks are lying... The only solid way to find out if this is an issue with your SSDs is to do plug-pull testing and find out. -- Craig Ringer http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services --------------070908010903070401020607 Content-Type: text/html; charset=windows-1252 Content-Transfer-Encoding: 7bit
On 12/12/2012 09:44 AM, Evgeny Shishkin wrote:
So far, more than a year already, i bought consumer ssds with 300-400$ hw raid. Cost effective and fast, may be not very safe, but so far so good. All data protection measures from postgresql are on, of course.

You're aware that many low end SSDs lie to the RAID controller about having written data, right? Even if the RAID controller sends a flush command, the SSD might cache the write in non-durable cache. If you're using such SSDs and you lose power, data corruption is extremely likely, because your SSDs are essentially ignoring fsync.

Your RAID controller's BBU won't save you, because once the disks tell the RAID controller the data has hit durable storage, the RAID controller feels free to flush it from its battery backed cache. If the disks are lying...

The only solid way to find out if this is an issue with your SSDs is to do plug-pull testing and find out.

-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services
--------------070908010903070401020607--