From nobody Tue Oct 17 23:11:46 2023 X-Original-To: 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 4S98rB4VRvz4x8w4 for ; Tue, 17 Oct 2023 23:11:54 +0000 (UTC) (envelope-from mirror176@hotmail.com) Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12olkn20826.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe5a::826]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "DigiCert Cloud Services CA-1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S98r94GDqz4FYw for ; Tue, 17 Oct 2023 23:11:53 +0000 (UTC) (envelope-from mirror176@hotmail.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=gU3o8I2a; spf=pass (mx1.freebsd.org: domain of mirror176@hotmail.com designates 2a01:111:f400:fe5a::826 as permitted sender) smtp.mailfrom=mirror176@hotmail.com; dmarc=pass (policy=none) header.from=hotmail.com; arc=pass ("microsoft.com:s=arcselector9901:i=1") ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HIcOD+0Z6VF650kFcfoaA6WOKWo8PIyuF/UgCVVDT8YZCZsO8rEJPZ52aOqipLScqjrXuhV5PQQCwbpU5PMMVPR5iPxlOY1k9pMJ40NgfsdgYJPxeRGzM+4zgJv5tWSrr8PKANfZ/GRVZolaWyR58XtXJ9aOFHKbs/Q23GFOFUQRA6XpGCTkRs1fRfQI/Hohn2KA06g8k2qMXhITAYF9bZaLrqrbhg+qzb0GKoKyOE6aw9bj+daexya51y1p90uX5ufOBjiqD2cdgjUZLiNjn7MCKD4slA3B8b2fGgiDu5/kzpvn/6iX3xJ5ffxkz5Fjqpsqi6fgNnL31KL9REYlVQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=DjOFLekXpsiIbXMBi5q2YClG3RC5/418o6/FGM+ii0A=; b=Eqs7ysKtKHXHqjgQ+0JBkYX2Ttbsbm/BAWZC7BfjEMNQiz9sazQ29AnjLDstAMoSFW3DWwUzW0BMXD39QkSnRAbJOEkkLfwSGiYpg43UNouYo1VE4JpLEDDkZZbaAdkQG+0H9tpA8jk3iYaGPz5k4ovmI6vl640xq9ZUvmJ8hF9bemHy3NjiV25vHm1GoRgacumVxFTQQeqjAWdn4hQYEfcgegAPHIpkJ7XJaWNb7MA/4KnHGn5edGVTRmNNAtEipxFkGFAATzwaP6z0Xc9tTil+SCbx14/JgUFeNffeYerT8TO60z9F469ntnW3yY/kYyl0SaTjT7S14oQ0k5v1OQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DjOFLekXpsiIbXMBi5q2YClG3RC5/418o6/FGM+ii0A=; b=gU3o8I2ajYB2BrAlaaZckow0kS4101OVeCj4cmtqqMCyaBX3e16yoo9cn4SU/5mu53NLeSEi20lHSnGKm7PrJU+wdUZTZiPud88i055qlKBcpK3Vh7pdTzPa/jJ7lh/w9PSWI4dTkV1LIbz896c98hAQ73si7V43ws5PeviavcUlkVa8dGi037H3L9ayY/17psX0dH7VDKhOLLDUOS6MvPYwLFxU8mEHwXju2Qf4A+wJbRYklkqMteZcjHt9rjiFr/1AgNX+71yW+q2+u7+PYKL8BmwBjvT0AOJL8ILHx5rXkeU6tloVFiW+mO+7OTElBicyfmSWpHTacTC001lkMA== Received: from CO1PR11MB4770.namprd11.prod.outlook.com (2603:10b6:303:94::19) by DS7PR11MB5968.namprd11.prod.outlook.com (2603:10b6:8:73::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6886.36; Tue, 17 Oct 2023 23:11:49 +0000 Received: from CO1PR11MB4770.namprd11.prod.outlook.com ([fe80::a542:a24f:4156:3a05]) by CO1PR11MB4770.namprd11.prod.outlook.com ([fe80::a542:a24f:4156:3a05%7]) with mapi id 15.20.6886.034; Tue, 17 Oct 2023 23:11:49 +0000 Message-ID: Date: Tue, 17 Oct 2023 16:11:46 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:102.0) Gecko/20100101 Thunderbird/102.14.0 Subject: Re: How to reinstall *ALL* pkgs Content-Language: en-US To: questions@freebsd.org References: <39b235c6-a8f1-4383-b491-24b32eed2b7d@app.fastmail.com> From: "Edward Sanford Sutton, III" In-Reply-To: <39b235c6-a8f1-4383-b491-24b32eed2b7d@app.fastmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-TMN: [vp/5h7hdEnD3FeVpQ+U4M9IYI1loOGKM] X-ClientProxiedBy: MN2PR07CA0016.namprd07.prod.outlook.com (2603:10b6:208:1a0::26) To CO1PR11MB4770.namprd11.prod.outlook.com (2603:10b6:303:94::19) X-Microsoft-Original-Message-ID: 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 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1PR11MB4770:EE_|DS7PR11MB5968:EE_ X-MS-Office365-Filtering-Correlation-Id: 0d0446a5-d2fb-4828-7591-08dbcf6670a6 X-Microsoft-Antispam: B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ZaRFZOMnA2MElYVG5uTlhqQitJR2ZQVTAzSW8vMy84ejhWbjMyWXQ4Wm9L?= =?utf-8?B?T2pqOTNWYjJqaGJQd3VRWVBqb3VtOHM5ZkhRSGdNWnFTTGNFaG5RSVA4YlBE?= =?utf-8?B?R2Q4MUlkbTBpb0JiMytJNVRPL2laTFF6VFV0Q1NoV3Y3Q2VHZzRWUnUzaW1B?= =?utf-8?B?V0psN21xb282Y2ZYMWV5WnJJenY2dVJJWU4wVGhZZVA3a3FNVnBMTG9PZmM3?= =?utf-8?B?MzBwYWdIZkdSbnVHTmt6RE9VaCswbHZRcWxtZHZxNHdwN2ZCUDZQOGZNTmUw?= =?utf-8?B?K3REWFduckNtZ21HUjZ0MVNiMzE0NlBUbWEyUTMyUFYzOStBZ2JsZ011dkJr?= =?utf-8?B?N0k0RERMZnNaVzlzaDJ5bThNWGV5Ym8vOHFhS1lacFIwUnYyem93cmUxdWh2?= =?utf-8?Q?9U5+K+QIdYNMjnNx7ztmW1TW/9SJ6Xas159aRRs+zobw=3D?= X-OriginatorOrg: sct-15-20-4755-11-msonline-outlook-e8f36.templateTenant X-MS-Exchange-CrossTenant-Network-Message-Id: 0d0446a5-d2fb-4828-7591-08dbcf6670a6 X-MS-Exchange-CrossTenant-AuthSource: CO1PR11MB4770.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Oct 2023 23:11:49.1315 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS7PR11MB5968 X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.32 / 15.00]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; ARC_ALLOW(-1.00)[microsoft.com:s=arcselector9901:i=1]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.82)[-0.816]; DMARC_POLICY_ALLOW(-0.50)[hotmail.com,none]; R_DKIM_ALLOW(-0.20)[hotmail.com:s=selector1]; R_SPF_ALLOW(-0.20)[+ip6:2a01:111:f400::/48]; MIME_GOOD(-0.10)[text/plain]; FROM_EQ_ENVFROM(0.00)[]; ASN(0.00)[asn:8075, ipnet:2a01:111:f000::/36, country:US]; MLMMJ_DEST(0.00)[questions@freebsd.org]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_NONE(0.00)[]; FROM_HAS_DN(0.00)[]; DKIM_TRACE(0.00)[hotmail.com:+]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FREEMAIL_FROM(0.00)[hotmail.com]; RCVD_COUNT_TWO(0.00)[2] X-Rspamd-Queue-Id: 4S98r94GDqz4FYw On 10/17/23 09:01, Dave Cottlehuber wrote: > On Tue, 17 Oct 2023, at 04:14, paul beard wrote: >> I have done something like this… >> ls /var/db/pkg/ | sed -r 's/(.*)-[0-9]/\1\ /g' | cut -f1 -d" " >> >> and pass that to pkg or to a file to clean it up (the sqlite databases >> are in there and don't need installing via pkg). > > I use this to track only the leaf packages, what's explicitly been installed > and the others will be pulled in automatically. > > NB make sure you're in the root /bin/sh & a console, not an (x)term > as this will remove *all* packages, including xorg window manager, > preferred shell etc. > > # pkg prime-origins | sort | uniq > /etc/packages.lst > ### edit and amend as required For that list, removals should be only removing packages you no longer want or are no longer offered. Additions would be to add packages you want to guarantee you keep installed even if dependent packages no longer automatically pull it in. `pkg query -e '%a = 0' %o` is the more complete "I installed this" list and will maximize features like `pkg autoremove` until doing an uninstall/reinstall from *origins types of lists where that is no longer guaranteed true and requires manually modifying the automatic flag on each package back to what you want to represent packages you desired are guaranteed installed vs only included if needed as a dependency. > ### force-delete all existing packages, rebootstrap & install > # pkg delete -fy \* > # pkg bootstrap -f > # pkg install -r FreeBSD `cat /etc/packages.lst` > > A+ > Dave >