Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 06 Sep 2023 17:20:22 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 273601] freebsd-update fills up /var/db/freebsd-update/files and never cleans them
Message-ID:  <bug-273601-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D273601

            Bug ID: 273601
           Summary: freebsd-update fills up /var/db/freebsd-update/files
                    and never cleans them
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: misc
          Assignee: bugs@FreeBSD.org
          Reporter: theraven@FreeBSD.org

There's a long forum thread about this going back almost 10 years:

https://forums.freebsd.org/threads/is-it-safe-to-clean-var-db-freebsd-updat=
e-files.45204/

FreeBSD update downloads files to /var/db/freebsd-update/files, which the m=
an
mage documents as the working directory for temporary files.  It is *probab=
ly*
safe to delete them (seems to be consensus on the forum, but freebsd-update
never does).  Deleting them is non-trivial because it downloads a *huge* nu=
mber
of tiny files here.=20=20

I've seen UFS-based installs die because they run out of inodes for all of
these files.  ZFS installs don't, but on a small VM with an 8 GiB disk (tha=
t's
small now, yay for living in the future), I ran out of disk space with this=
.=20
After pruning it a few months ago, it's grown to 1.2G.

At the very lest, it would be great for someone to document *when* it is sa=
fe
to delete these things.  Ideally, we'd use tmpfs for most of them (they're
downloaded and then extracted immediately) and store the ones that are need=
ed
after reboot somewhere that persists and delete them after they're installe=
d.

I believe that they might be kept for freebsd-update rollback, but since
12.something freebsd-update has created ZFS boot environments (thank you
whoever added that feature!) and so the rollback feature is not necessary on
ZFS systems (and has never worked for me when I've tried it, but maybe I was
just unlucky).

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-273601-227>