From owner-freebsd-questions@freebsd.org Sun Sep 6 16:26:54 2015 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 053179CC207 for ; Sun, 6 Sep 2015 16:26:54 +0000 (UTC) (envelope-from brandon.wandersee@gmail.com) Received: from mail-ig0-f172.google.com (mail-ig0-f172.google.com [209.85.213.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CD05917C9 for ; Sun, 6 Sep 2015 16:26:53 +0000 (UTC) (envelope-from brandon.wandersee@gmail.com) Received: by igcpb10 with SMTP id pb10so45464690igc.1 for ; Sun, 06 Sep 2015 09:26:47 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=references:from:to:cc:subject:in-reply-to:date:message-id :mime-version:content-type; bh=Cq5qRYpMRo3wKI54oANVZBG5isbUe7SUnKhKt/VvKYw=; b=dol3eAcEdze/mBQ0J+77V0xQQfPAW6EmW6W55Wqmd6ZRjpzLY5Uj7y4gecMD3B/3ZV LMssB0aqUu3K0qpwsqmx9wHMn9nm1bdA0aJIGtnLzKgmhESADacXAD7w+aMmlczF23J4 4f1zRPHjEbi8CVdnZKLAj+vFz79r+qA+dpgYU4bsp2YDL252bpj5RSAYcih2McBNCopt SJj+E6WJZGI2Rpeo+Urwj6gJQzpe1znMhS1sgx7W8I4bfq6/Bnq7/yj89ifviQxFN5sl 7OU9DcaM6cH3pq/McAalrA9grYVxMlZBCLjlrP4k8TeN9QSw+KFeDvn2E/rdB+3aodte ENbw== X-Received: by 10.50.62.81 with SMTP id w17mr24525849igr.0.1441556807760; Sun, 06 Sep 2015 09:26:47 -0700 (PDT) Received: from WorkBox.Home.gmail.com (174-30-208-115.mpls.qwest.net. [174.30.208.115]) by smtp.gmail.com with ESMTPSA id p65sm6122177ioe.26.2015.09.06.09.26.46 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 06 Sep 2015 09:26:46 -0700 (PDT) References: <55E01DAE.1020709@infracaninophile.co.uk> <20150828084643.GB1274@xtaz.uk> <864mjj1fh3.fsf@WorkBox.Home> From: Brandon J. Wandersee To: Warren Block Cc: freebsd-questions@freebsd.org Subject: Re: Replacing Drive with SSD In-reply-to: Date: Sun, 06 Sep 2015 11:26:45 -0500 Message-ID: <8637yro6nu.fsf@WorkBox.Home> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Sep 2015 16:26:54 -0000 Warren Block writes: > The SSD keeps a map of which blocks have been written. So writing just > once with dd is not a wear problem. The problem is that now the SSD has > no way of knowing whether that block has real data on it or not. So it > can't swap it for wear leveling. That's what trim does--when a file is > deleted, the filesystem uses trim to notify the SSD that those blocks > are no longer in use. Would this also apply to a *single file* written using dd? Your SSD guide recommends creating a swap file from /dev/zero using dd: > Because the data goes through the file system, TRIM will be used, and > the swap file can be resized without repartitioning the SSD. So is the problem with dd and SSDs only relevant when targeting a whole block device? -- ================================================================= :: Brandon Wandersee :: :: brandon.wandersee@gmail.com :: ================================================================== 'A common mistake that people make when trying to design something completely foolproof is to underestimate the ingenuity of complete fools.' - Douglas Adams ==================================================================