From owner-freebsd-scsi@freebsd.org Fri Jun 14 10:25:34 2019 Return-Path: Delivered-To: freebsd-scsi@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1919515CC6D9 for ; Fri, 14 Jun 2019 10:25:34 +0000 (UTC) (envelope-from peter.blok@bsd4all.org) Received: from smtpq6.tb.mail.iss.as9143.net (smtpq6.tb.mail.iss.as9143.net [212.54.42.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5B34C8C8EC for ; Fri, 14 Jun 2019 10:25:32 +0000 (UTC) (envelope-from peter.blok@bsd4all.org) Received: from [212.54.42.136] (helo=smtp12.tb.mail.iss.as9143.net) by smtpq6.tb.mail.iss.as9143.net with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1hbjOi-00033L-Lc; Fri, 14 Jun 2019 12:25:28 +0200 Received: from 94-209-122-217.cable.dynamic.v4.ziggo.nl ([94.209.122.217] helo=wan0.bsd4all.org) by smtp12.tb.mail.iss.as9143.net with esmtp (Exim 4.90_1) (envelope-from ) id 1hbjOi-0006T3-Gq; Fri, 14 Jun 2019 12:25:28 +0200 Received: from newnas (localhost [127.0.0.1]) by wan0.bsd4all.org (Postfix) with ESMTP id 944D91F2; Fri, 14 Jun 2019 12:25:27 +0200 (CEST) X-Virus-Scanned: amavisd-new at bsd4all.org Received: from wan0.bsd4all.org ([127.0.0.1]) by newnas (newnas.bsd4all.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5sKSx_LYIaLq; Fri, 14 Jun 2019 12:25:26 +0200 (CEST) Received: from [192.168.1.65] (unknown [192.168.1.65]) by wan0.bsd4all.org (Postfix) with ESMTPSA id 6E85A1EE; Fri, 14 Jun 2019 12:25:26 +0200 (CEST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: Re: Bad SSD drive - what happens with unreadable data From: peter.blok@bsd4all.org In-Reply-To: <20190613133439.GE66314@mithlond.kdm.org> Date: Fri, 14 Jun 2019 12:25:25 +0200 Cc: freebsd-scsi@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <20190613133439.GE66314@mithlond.kdm.org> To: "Kenneth D. Merry" X-Mailer: Apple Mail (2.3445.104.11) X-SourceIP: 94.209.122.217 X-Ziggo-spambar: / X-Ziggo-spamscore: 0.0 X-Ziggo-spamreport: CMAE Analysis: v=2.3 cv=Zo2T1OzG c=1 sm=1 tr=0 a=0XONDDbZk2SpjknwKA3Xxg==:17 a=jpOVt7BSZ2e4Z31A5e1TngXxSK0=:19 a=kj9zAlcOel0A:10 a=dq6fvYVFJ5YA:10 a=Gw1ouQRIAAAA:8 a=6Q3WNqvRAAAA:8 a=TlfEPOs9qqefzcL246AA:9 a=CjuIK1q_8ugA:10 a=K9VNa7-dmgn0gKMGrBPS:22 a=I8PBwKCn76L9oNdl0isp:22 X-Ziggo-Spam-Status: No X-Spam-Status: No X-Spam-Flag: No X-Rspamd-Queue-Id: 5B34C8C8EC X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of peter.blok@bsd4all.org designates 212.54.42.169 as permitted sender) smtp.mailfrom=peter.blok@bsd4all.org X-Spamd-Result: default: False [-3.49 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCVD_COUNT_FIVE(0.00)[6]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+a:smtp.ziggo.nl/16]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[bsd4all.org]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: smtp.bsd4all.org]; RCPT_COUNT_TWO(0.00)[2]; FROM_NO_DN(0.00)[]; NEURAL_HAM_SHORT(-0.83)[-0.834,0]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; IP_SCORE(-0.74)[ipnet: 212.54.32.0/20(-2.95), asn: 33915(-0.78), country: NL(0.01)]; RCVD_IN_DNSWL_LOW(-0.10)[169.42.54.212.list.dnswl.org : 127.0.5.1]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:33915, ipnet:212.54.32.0/20, country:NL]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[217.122.209.94.zen.spamhaus.org : 127.0.0.11] X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jun 2019 10:25:34 -0000 Hi Ken, Yes I already had changed the time-outs and retries. I ended up using = ddrescue out of the ports collection. Despite the amount of read errors = I was able to recover the important stuff. SSD drive is going back under warranty (hopefully). It is less than a = year old and hardly used. Peter > On 13 Jun 2019, at 15:34, Kenneth D. Merry wrote: >=20 > On Thu, Jun 13, 2019 at 13:02:48 +0200, peter.blok@bsd4all.org wrote: >> Hi, >>=20 >> I have a bad SSD drive. If I read it with dd and conv=3Dnoerror, what = happens with the unreadable areas? Does it fill with zeroes, or does the = driver still copy what it was able to read? >>=20 >> I???m getting ATA status 51 back, many blocks in a row. Followed by = chunks of readable data, followed by unreadable data. >>=20 >> Is there a modepage or something else to tell the drive to pass on = the bad data? >>=20 >> Any other ideas? >=20 > You might try the recoverdisk(1) utility. It is designed for that = sort of > situation. >=20 > One of the recommendations in the recoverdisk(1) man page is to lower = the > retry count for the disk driver you're using, so you don't wind up = retrying > a lot in situations where the drive itself has tried and failed to = read the > data. >=20 > In looking at the source, it appears tht it will only write out the = blocks > it is able to read successfully. IMO, it would be good to have at = least an > option to write zeros in output file in the areas where the reads = failed. >=20 > Ken > --=20 > Kenneth Merry > ken@kdm.org