From nobody Thu Jan 6 10:37:03 2022 X-Original-To: freebsd-questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id D7074192B566 for ; Thu, 6 Jan 2022 10:37:16 +0000 (UTC) (envelope-from mail@ozzmosis.com) Received: from relay12.mail.gandi.net (relay12.mail.gandi.net [217.70.178.232]) (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 4JV2pz5mrWz3jYW for ; Thu, 6 Jan 2022 10:37:15 +0000 (UTC) (envelope-from mail@ozzmosis.com) Received: (Authenticated sender: ozzmosis@ozzmosis.com) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 1C5C7200002 for ; Thu, 6 Jan 2022 10:37:07 +0000 (UTC) Received: by blizzard.ozzmosis.com (Postfix, from userid 1001) id 44198110C28; Thu, 6 Jan 2022 21:37:03 +1100 (AEDT) Date: Thu, 6 Jan 2022 21:37:03 +1100 From: andrew clarke To: freebsd-questions@freebsd.org Subject: Re: size of /var/db/freebsd-update Message-ID: <20220106103703.j7v3b36jpltdq4eh@ozzmosis.com> References: List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20211029 X-Rspamd-Queue-Id: 4JV2pz5mrWz3jYW X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of mail@ozzmosis.com designates 217.70.178.232 as permitted sender) smtp.mailfrom=mail@ozzmosis.com X-Spamd-Result: default: False [-3.37 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:217.70.178.192/26]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.97)[-0.971]; DMARC_NA(0.00)[ozzmosis.com]; NEURAL_HAM_SHORT(-1.00)[-1.000]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:29169, ipnet:217.70.176.0/20, country:FR]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_IN_DNSWL_LOW(-0.10)[217.70.178.232:from] X-ThisMailContainsUnwantedMimeParts: N On 2022-01-03 19:03:41, tech-lists (tech-lists@zyxst.net) wrote: > $ sudo du -sh /var/db/freebsd-update > 5.8G /var/db/freebsd-update > > this is a huge amount of space, as the vm is 64GB. What can I do to free up > the space without breaking freebsd-update? I guess it's the update history > but couldn't find anything in the manpage on how to maintain it > with regards to size. After a successful update it's safe to delete that directory entirely. $ sudo rm -rf /var/db/freebsd-update/ The only minor hiccup is freebsd-update will fail now that /var/db/freebsd-update/ no longer exists: $ sudo freebsd-update fetch freebsd-update: Directory does not exist or is not writable: /var/db/freebsd-update So just recreate it manually: $ sudo mkdir /var/db/freebsd-update Now the directory will be repopulated with metadata the next time you run "freebsd-update fetch": $ sudo freebsd-update fetch Looking up update.FreeBSD.org mirrors... 2 mirrors found. Fetching public key from update2.freebsd.org... done. Fetching metadata signature for 13.0-RELEASE from update2.freebsd.org... done. Fetching metadata index... done. Fetching 2 metadata files... done. Inspecting system... done. Preparing to download files... done. No updates needed to update system to 13.0-RELEASE-p5. $ sudo ls -l /var/db/freebsd-update total 79 drwxr-xr-x 2 root wheel 4 6 Jan 21:34 files -rw-r--r-- 1 root wheel 800 4 Nov 07:14 pub.ssl -rw-r--r-- 1 root wheel 50 6 Jan 21:34 serverlist -rw-r--r-- 1 root wheel 50 6 Jan 21:34 serverlist_full -rw-r--r-- 1 root wheel 25 6 Jan 21:34 serverlist_tried -rw-r--r-- 1 root wheel 112 6 Jan 21:34 tag -rw-r--r-- 1 root wheel 150 6 Jan 21:34 tINDEX.present