From owner-freebsd-questions@freebsd.org Thu Apr 13 10:08:33 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 89FAAD3CB84 for ; Thu, 13 Apr 2017 10:08:33 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) (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 4CCED9FD for ; Thu, 13 Apr 2017 10:08:32 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 5D6E421A5F for ; Thu, 13 Apr 2017 06:08:27 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Thu, 13 Apr 2017 06:08:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zyxst.net; h= content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=xY/JJUpUdNnmyg7U0O n4cdxr5ycO75h0Lvop+BzIAik=; b=Mal7f+oGS67g9JX3cCOZiANh45/oCttyhO FAP5Iv8VcarJn2z4yMmzGjV3iQZ6iVL0WUe8SBxQrEyd2WnCsC/yOod2t9Hf0p5E F1ZE187HF9DZ/AORIbnx7C6tmA+kifMforlAvlZpRKj6JGNzZGNUrrc6TazICC/r /dijE/Y8EBTSAfKW894hViaHYl8INz7BbCv23KTXuvDfq7GkaImPUJBUgEJsGl8B P70mE4LVEtn6XZU44dnry7fWpT2iMn1g4DPqejB5PxduxOKbFK2PQ5Ldksb7Axui q9E/58yJmpeWqGiMY2yoLttqMLwMjxZMl+V8EKWjETWfuOWKpaGg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=xY/JJUpUdNnmyg7U0On4cdxr5ycO75h0Lvop+BzIAik=; b=mBMSmXX0 y4182Y4eMyJnaIOyMhr1AXl2pc/FxcG3MlUOPcubXOKnFBMBreoqJP7TB5F8wBok DwoESvNO+Om9aZjN9zzbazz7fIiMp6KK4wK/rYgyKESR3WsgKHuUDPGdrlL7qznN O5QPykCLcsn8R3sRzTKkiqE+Yf4Teg0bnHGOTWvowrTykopJVTP1dYESaXhmkIT6 iOM1YM65orNvmRycJpn9iCKpkogazcAv5But5a4ZN7FBcT0vRbu6TL5pZKvciQ4I sIsdiy3HNcFESXIPyWli3tXY+N94gtOYzAyRnAAKWlAibeVPj9F501+WseS7AkYu d48Y/GZj+VVcIA== X-ME-Sender: X-Sasl-enc: 77zVH7NC7um8bVf35gcMxQW1nXF29wBX3qOh+BPxKC3Y 1492078107 Received: from pumpkin.growveg.org (pumpkin.growveg.org [82.70.91.101]) by mail.messagingengine.com (Postfix) with ESMTPA id F4134241E3 for ; Thu, 13 Apr 2017 06:08:26 -0400 (EDT) Subject: Re: hopefully simple query regarding dd To: freebsd-questions@freebsd.org References: <7ed0944d-56d0-fc10-629b-b90067f48651@zyxst.net> <20170413103601.ae71e4fa9a2b5d9b024a71fc@sohara.org> From: tech-lists Message-ID: <33df8ac0-3d45-2945-fd4f-f4068ce60f8c@zyxst.net> Date: Thu, 13 Apr 2017 11:08:23 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.0 MIME-Version: 1.0 In-Reply-To: <20170413103601.ae71e4fa9a2b5d9b024a71fc@sohara.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Apr 2017 10:08:33 -0000 On 13/04/2017 10:36, Steve O'Hara-Smith wrote: > It should be safe and work, assuming that what you want to do is > read and rewrite every block. You should probably think very hard about > what you want it to do in the case of read and/or write errors. > > I'm not sure why you'd want to do it though, discs are not > particularly volatile storage even on timescales of years. > > Of course if it ever gets a read error that passes the CRC > (aka silent corruption) it will cement the error in stone for you by > writing it back. > > If you are really concerned about long term data retention then I > suggest ZFS with plenty of redundancy (at least two drives redundancy) and a > regular scrub. Hi, The context is this: old netbook, slow cpu (boo!) low power (yay!) .. was thinking of making it a server on either the local or external LAN. AMD C-70 APU with Radeon(tm) HD Graphics (998.20-MHz K8-class CPU) real memory = 4294967296 (4096 MB) avail memory = 3781300224 (3606 MB) ATA8-ACS SATA 2.x device ada0: Serial Number WD-WX51A3312496 ada0: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes) ada0: Command Queueing enabled ada0: 305245MB (625142448 512 byte sectors) ada0: quirks=0x1<4K> Brand new freebsd-12 install as of yesterday. I think ZFS might just kill it though. Before installing, I ran a dd if=/dev/zero of=/dev/ada0 bs=1m conv=noerror from the shell option in the installer because if there were blocks giving errors, I wanted to re-map them somewhere safe. After installing, the first thing I did was to install and run smartd to see where I was with the disk. I knew previously the disk was likely to have errors. Here's the relevant stats: 9 Power_On_Hours -O--CK 085 085 000 - 11379 191 G-Sense_Error_Rate -O--CK 001 001 000 - 759 5 Reallocated_Sector_Ct PO--CK 183 183 140 - 143 197 Current_Pending_Sector -O--CK 001 001 000 - 65216 198 Offline_Uncorrectable ----CK 100 253 000 - 0 196 Reallocated_Event_Count -O--CK 196 196 000 - 4 194 Temperature_Celsius -O---K 104 089 000 - 39 Basically, I want that Current_Pending_Sector number to go to 0. I guess if it doesn't, then it's either replace the disk or it's time to dispose of the netbook. Right now it's rebuilding 12 with witness/invariants disabled, so I can't really do the dd thing I earlier asked about right now. I just needed to know if it could be run without having to reinstall. thanks, -- J.