From nobody Fri Aug 8 15:03:41 2025 X-Original-To: freebsd-pkgbase@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 4bz6k25Rvmz641cW; Fri, 08 Aug 2025 15:03:54 +0000 (UTC) (envelope-from vermaden@interia.pl) Received: from smtpo73.interia.pl (smtpo73.interia.pl [217.74.67.73]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4bz6k229lwz3KPr; Fri, 08 Aug 2025 15:03:54 +0000 (UTC) (envelope-from vermaden@interia.pl) Authentication-Results: mx1.freebsd.org; none Date: Fri, 08 Aug 2025 17:03:41 +0200 From: vermaden Subject: Re: PKGBASE Removes FreeBSD Base System Feature To: Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?= , "sthaug@nethelp.no" Cc: "freebsd-current@freebsd.org" , "freebsd-stable@freebsd.org" , freebsd-pkgbase@FreeBSD.org X-Mailer: interia.pl/pf09 In-Reply-To: <86h5yi43kp.fsf@ltc.des.dev> References: <20250808.091053.1322595805169591390.sthaug@nethelp.no> <86h5yi43kp.fsf@ltc.des.dev> X-Originating-IP: 45.148.42.1 Message-Id: List-Id: Packaging the FreeBSD base system List-Archive: https://lists.freebsd.org/archives/freebsd-pkgbase List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-pkgbase@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=interia.pl; s=biztos; t=1754665425; bh=7IwM1nAjTL+19LbCl7Bmk+Q8sRz+scmgUr14snucekg=; h=Date:From:Subject:To:Message-Id:MIME-Version:Content-Type; b=vEj0cuMUfMnE79J5QBevhmUggjM1M8GBghwFEd9Rqntr3VXTfPIyevJZb3W9YRoz1 3tZcOKqEBM6rGdzS7KPbBpleqifyfVmrYwMCcu3CepVepRyZXcEfPi8cwYYdAPziA9 T41Sj/i0SQTA1AHQ2/qIWMqh9oswgjn0Fcpong7U= X-Rspamd-Queue-Id: 4bz6k229lwz3KPr X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16138, ipnet:217.74.64.0/22, country:PL] Current 'vital' thing does NOTHING to protect FreeBSD Base System. I literally just wiped one of my Jails because of this 'vital' protection. That 'vital' thing is useless in current state after issuing this command: # pkg delete -af Log below. Unbootable and unusable FreeBSD left after the command that only removed pa= ckages without PKGBASE and with PKGBASE you are left with dust. Even /rescue is gone. root@bsdinstalljail:/ # pkg info FreeBSD-acct-14.1p1 System Accounting Utilities FreeBSD-acct-man-14.1 System Accounting Utilities (Manual Pages) FreeBSD-acpi-14.1 ACPI Utilities (...) FreeBSD-zfs-dev-14.1p1 ZFS Libraries and Utilities (Development Fil= es) FreeBSD-zfs-man-14.1 ZFS Libraries and Utilities (Manual Pages) FreeBSD-zoneinfo-14.1p7 zoneinfo package beadm-1.3.5_1 Solaris-like utility to manage Boot Environm= ents on ZFS pkg-2.2.1 Package manager root@bsdinstalljail:/ # pkg delete -af Checking integrity... done (0 conflicting) Deinstallation has been requested for the following 271 packages (of 0 pack= ages in the universe): Installed packages to be REMOVED: FreeBSD-acct: 14.1p1 FreeBSD-acct-man: 14.1 FreeBSD-acpi: 14.1 (...) [bsdinstalljail.lab.org] [268/271] Deleting files for FreeBSD-zfs-man-14.1:= 100% [bsdinstalljail.lab.org] [269/271] Deinstalling FreeBSD-zoneinfo-14.1p7... [bsdinstalljail.lab.org] [269/271] Deleting files for FreeBSD-zoneinfo-14.1= p7: 100% [bsdinstalljail.lab.org] [270/271] Deinstalling beadm-1.3.5_1... [bsdinstalljail.lab.org] [270/271] Deleting files for beadm-1.3.5_1: 100% [bsdinstalljail.lab.org] [271/271] Deinstalling pkg-2.2.1... [bsdinstalljail.lab.org] [271/271] Deleting files for pkg-2.2.1: 100% pkg: Cannot runscript POST-DEINSTALL:No such file or directory You may need to manually remove /usr/local/etc/pkg.conf if it is no longer = needed. root@bsdinstalljail:/ # ls /bin/sh: ls: not found root@bsdinstalljail:/ # vi /bin/sh: vi: not found root@bsdinstalljail:/ # pkg /bin/sh: pkg: not found root@bsdinstalljail:/ # pkg-static /bin/sh: pkg-static: not found root@bsdinstalljail:/ # reboot /bin/sh: reboot: not found root@bsdinstalljail:/ # goodbye /bin/sh: goodbye: not found root@bsdinstalljail:/ # /rescue/ls /rescue /bin/sh: /rescue/ls: not found root@bsdinstalljail:/ # /rescue/ls.pkgsave /rescue rescue: ls.pkgsave not compiled in usage: rescue ..., where is one of: cat chflags chio chmod cp date dd df echo ed red expr getfacl hostname ken= v kill ln link ls mkdir mv pkill pgrep ps pwd realpath rm unlink rmdir setfa= cl sh -sh sleep stty sync test [ csh -csh tcsh -tcsh camcontrol clri devfs dm= esg dump rdump dumpfs dumpon fsck fsck_ffs fsck_4.2bsd fsck_ufs fsck_msdosfs f= sdb fsirand gbde geom glabel gpart ifconfig init kldconfig kldload kldstat kldunload ldconfig md5 mdconfig mdmfs mknod mount mount_cd9660 mount_msdos= fs mount_nfs mount_nullfs mount_udf mount_unionfs newfs newfs_msdos nos-tun reboot fastboot halt fasthalt restore rrestore rcorder route savecore shut= down poweroff swapon sysctl tunefs umount ccdconfig ping ping6 rtsol ipf routed rtquery bectl zfs zpool bsdlabel disklabel fdisk dhclient head mt sed tail= tee gzip gunzip gzcat zcat bzip2 bunzip2 bzcat less more xz unxz lzma unlzma x= zcat lzcat zstd unzstd zstdcat zstdmt fetch tar nc vi ex id groups whoami iscsi= ctl zdb chroot chown chgrp iscsid rescue Temat: Re: PKGBASE Removes FreeBSD Base System Feature Data: 2025-08-08 10:31 Nadawca: "Dag-Erling Sm=C3=B8rgrav" <des@FreeBSD.org> Adresat: sthaug@nethelp.no;=20 DW: freebsd-current@freebsd.org; freebsd-stable@freebsd.org;=20 >=20 >> sthaug@nethelp.no writes: >> - It's important to have a clean separation between the base system >> (whether that is installed using the package system or not) and the >> rest. An easy way to list "these are the base system packages" is >> absolutely needed. >=20 > You can easily create an alias for this: >=20 > pkg query -e '%o =3D base' %n >=20 > If you want something closer to `pkg info`, try: >=20 > pkg query -e '%o =3D base' '%n-%v %c' | column -tl 2 >=20 >> - Maybe there should be an extra step if you try to delete packages >> from the base system? >=20 > There already is: >=20 > % sudo pkg delete FreeBSD-clibs > Checking integrity... done (0 conflicting) > The following package(s) are locked or vital and may not be removed: > =20 > FreeBSD-clibs > =20 > 1 packages requested for removal: 1 locked, 0 missing >=20 > The only matter that remains to be settled is which packages should be > marked vital: >=20 > % pkg query -e '%V =3D 1' %n > FreeBSD-clibs > FreeBSD-runtime >=20 > DES > --=20 > Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org >=20 >=20 >=20