From owner-freebsd-questions@freebsd.org Thu Oct 22 14:32:05 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 9937EA1CAA2 for ; Thu, 22 Oct 2015 14:32:05 +0000 (UTC) (envelope-from amvandemore@gmail.com) Received: from mail-wi0-x22a.google.com (mail-wi0-x22a.google.com [IPv6:2a00:1450:400c:c05::22a]) (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 2EE191F85 for ; Thu, 22 Oct 2015 14:32:05 +0000 (UTC) (envelope-from amvandemore@gmail.com) Received: by wicll6 with SMTP id ll6so122066870wic.1 for ; Thu, 22 Oct 2015 07:32:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=g0K9+o8Ix1H3liTIX7nDu+WXWsQy7rfaW2apGh1y3iI=; b=F4PiOniHJ9f1cIdPrlAv7PvB8+cOhad0EjG//tN+KUlFzElPnh5QhByTBuJJ8EAkna lpFbKtnyplt/N2pgYAkoXsk9c3zLqZKfsz7fXTUtnntllB2aFCeB2KYA1wUCjJls+j7F YCZlzN8Bt3tCrG6KkPQFC2+/tUb9W71i2rpbPdI/4x2GOt0T/yejUztS/WJOaJVHCMmS 2pwEpphpOJZ7LdKW6vK6gzQwbzvYi6jT6VcYKtuDMfqgl/LdXV4YWGygSKuChDGnMFkE vjO5oBnaJcdfDxaI1mh7NMzyWhZmrYU/GsYSHRHYgFRCHg0l+Sq13GQn/RMQ7WZRF6Vu FANQ== MIME-Version: 1.0 X-Received: by 10.180.184.138 with SMTP id eu10mr42812537wic.25.1445524322686; Thu, 22 Oct 2015 07:32:02 -0700 (PDT) Received: by 10.194.16.231 with HTTP; Thu, 22 Oct 2015 07:32:02 -0700 (PDT) In-Reply-To: <20151022131510.GY87605@mordor.lan> References: <867fmh12nq.fsf@WorkBox.Home> <86pp081glq.fsf@WorkBox.Home> <20151021143525.GX87605@mordor.lan> <86lhaw107r.fsf@WorkBox.Home> <20151022131510.GY87605@mordor.lan> Date: Thu, 22 Oct 2015 09:32:02 -0500 Message-ID: Subject: Re: gjournal and TRIM: A safe combination? From: Adam Vande More To: Julien Cigar Cc: "Brandon J. Wandersee" , FreeBSD Questions , krad Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 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: Thu, 22 Oct 2015 14:32:05 -0000 On Thu, Oct 22, 2015 at 8:15 AM, Julien Cigar wrote: > On Wed, Oct 21, 2015 at 02:38:16PM -0500, Brandon J. Wandersee wrote: > > > > Julien Cigar writes: > > > Correct me if I'm wrong but, unless there is a bug in Soft Updates > (SU), > > > your FS will, in theory, never be corrupted with SU only. > > > > If I read this right, then, would gjournal be overkill for typical > > desktop/laptop use? UFS2 is perhaps the only filesystems I've ever > > encountered in common use that doesn't have data journaling enabled by > > default, so that's thrown me off somewhat... > > It depends of your needs, but for a typicaly desktop use it seems a bit > overkill to me. > > Contrary to other filesystems UFS doesn't need journaling to avoid > _corruption_ as SU is an alternate approach to maintain metadata > integrity. > > One important thing to remember is that neither SU, or SU+J, or any > journaled metadata prevents data loss: corruption != data loss. This is > where gjournal (and data=journal on EXT-like FS) comes in as datas and > metadatas are written in the journal _before_, so you avoid corruption > and data loss. > gjournal nor data=journal nor COW prevent data loss. They simply ensure both meta-data and data are consistent. In general though they do reduce the risk of data loss at a high cost in journaled scenarios. -- Adam