From owner-freebsd-hackers@freebsd.org Wed Aug 26 05:16:05 2020 Return-Path: Delivered-To: freebsd-hackers@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B6B653C97A9 for ; Wed, 26 Aug 2020 05:16:05 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BbvGD6mL8z4gSn; Wed, 26 Aug 2020 05:16:04 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: by mail-ej1-x634.google.com with SMTP id a26so1116001ejc.2; Tue, 25 Aug 2020 22:16:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ZQpZk1gTRM0lYnaGdhdegwU2kpfiB96wjRRfPNKrmUc=; b=rwISkMXJzykNn6c5vODF78AhxpB2l8DDHzKnNWuYuaKAAK9NtmXPnAwmFkop+GMnes vegMy6+DPzaxI1VvxEHPMk5wmckkzOz9Za3/76NP95p6GVlpPvp1lM0Ps17qc91thYLw yXm2at2ZutNsYevd+z+TZHnTcoikwHwDvn33as8EHmnjUaXfmpdrxM5Xl86amceulKII FYCkaM2qHKOzCVl4gZtSwwuSvlmtk8THGh8Rht0G/n3HLL6lDZJfFqYmH/Z6OGjUYshc hnsORhns5bfzFtsVFddvd1pi9lzI0ZR4EFABwaHVqkvTaMeAomm2UZQzKH4Gjgxv++wp I4Ow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ZQpZk1gTRM0lYnaGdhdegwU2kpfiB96wjRRfPNKrmUc=; b=WyQLqP+ZLQb3Sicq9l6OCrfgZZjClJeO7NNw3cHXjxAVtKDmL9hgj8tkhoBqSL6WRw u4qY3hxKH2SbXJO7DB/oK/n0Biy4WI2cIwxHW8tOIxCekyVQBupsEcND2hQeEqMPk5cu 46SWLasg5aOZ2bq2/AAUWyD25/ncXkXlQwKriAEkYiTLC3OrZuJwUW74t+UMMMClQqiI zvpdyEggV30Q54530nWX6mq6gRsGDnIC3YpSVz084xGFE0HKE6xFuEYdEvBamWwaI/XI Kuf67fEZxK+Pt+u6s9zvJDmS94f2Gs5JUj160Uz2tjjZDxDPGytPrCxpre85AfmcxH6G QG2A== X-Gm-Message-State: AOAM532BwG4uTgDUQ5FiAdP+k5T0rkMUkAY6kueXKhhrUU2zyRF4GWyr CtfdgPhycHuUS8phF1mlCCvYCgtlOPqqAhbusAXisdQ= X-Google-Smtp-Source: ABdhPJwsYHcz95EMGGmwSKIHTmL6uNpR3DgVPN/3HVAXLZTYaB8eMSwwsdgSe+xSzE2lR4wVh3jdYfS8/myiRvbghAs= X-Received: by 2002:a17:906:4f08:: with SMTP id t8mr14275699eju.164.1598418961828; Tue, 25 Aug 2020 22:16:01 -0700 (PDT) MIME-Version: 1.0 References: <924f4c6e-f07e-99fb-ac4a-924efbd3dba3@freebsd.org> In-Reply-To: <924f4c6e-f07e-99fb-ac4a-924efbd3dba3@freebsd.org> From: Zaphod Beeblebrox Date: Wed, 26 Aug 2020 01:15:50 -0400 Message-ID: Subject: Re: Boot time TRIM ? To: Allan Jude Cc: FreeBSD Hackers X-Rspamd-Queue-Id: 4BbvGD6mL8z4gSn X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=rwISkMXJ; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of zbeeble@gmail.com designates 2a00:1450:4864:20::634 as permitted sender) smtp.mailfrom=zbeeble@gmail.com X-Spamd-Result: default: False [-2.13 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; NEURAL_HAM_MEDIUM(-0.79)[-0.793]; FROM_HAS_DN(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; FREEMAIL_FROM(0.00)[gmail.com]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; NEURAL_HAM_LONG(-0.96)[-0.960]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::634:from]; NEURAL_HAM_SHORT(-0.38)[-0.382]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; SUBJECT_ENDS_QUESTION(1.00)[]; MAILMAN_DEST(0.00)[freebsd-hackers]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Aug 2020 05:16:05 -0000 On Tue, Aug 25, 2020 at 10:07 PM Allan Jude wrote: > Note, as of the import last night, the version of OpenZFS in FreeBSD now > supports a persistent L2ARC (cache) device. So on boot, it will > reprocess the list of buffers in the cache device and repopulate the ARC. > > So for a cache device, there is not much point in worrying about TRIM > across reboots. > > For the SLOG device, you basically overwrite the same blocks repeatedly, > and TRIM is likely a waste of time. You might be better off > under-provisioning instead. There really isn't much use for more than 16 > or 32 GB of SLOG anyway. > > This is good news. How long until we see that in 12.x if at all? I think the performance of my L2ARC is going to get a good bump when this comes online. In reaction to others, the NVME has swap, 2 logs and one cache. The logs are both 24G, the swap is 64G and the cache is the rest. When building poudriere it seems to write between 1T and 2T per day in total. The swap is lightly used. 6 or 7 percent --- the swap size is equal to the memory size at 64G right now. Obviously my concern is that TRIM'd stuff doesn't need to move from MLC to TLC or whathaveyou. Even after a reboot.