NetBSD Problem Report #56594

From mlelstv@arnold.localdomain  Fri Dec 31 09:14:05 2021
Return-Path: <mlelstv@arnold.localdomain>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 1F4C81A9239
	for <gnats-bugs@gnats.NetBSD.org>; Fri, 31 Dec 2021 09:14:05 +0000 (UTC)
Message-Id: <20211231090839.776F74D746@slowpoke.1st.de>
Date: Fri, 31 Dec 2021 09:08:39 +0000 (UTC)
From: mlelstv@netbsd.org
Reply-To: mlelstv@netbsd.org
To: gnats-bugs@NetBSD.org
Subject: pbulk leaves dangling compat symlinks
X-Send-Pr-Version: 3.95

>Number:         56594
>Category:       pkg
>Synopsis:       pbulk leaves dangling compat symlinks
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Dec 31 09:15:00 +0000 2021
>Originator:     mlelstv@netbsd.org
>Release:        NetBSD 9.99.85
>Organization:

>Environment:


System: NetBSD slowpoke 9.99.85 NetBSD 9.99.85 (SLOWPOKE) #13: Tue Jun 15 22:51:58 UTC 2021 mlelstv@slowpoke:/scratch2/obj.amd64/scratch/netbsd-current/src/sys/arch/amd64/compile/SLOWPOKE amd64
Architecture: x86_64
Machine: amd64
>Description:
After running pbulk, the build hosts have dangling symlinks in /lib pointing
to files in /usr/pkg/emul like this:

lrwxr-xr-x   1 root  wheel       39 Sep 24 13:05 libc.so.12.181 -> /usr/pkg/emul/netbsd/lib/libc.so.12.181
lrwxr-xr-x   1 root  wheel       39 Sep 24 13:05 libedit.so.3.0 -> /usr/pkg/emul/netbsd/lib/libedit.so.3.0
lrwxr-xr-x   1 root  wheel       38 Sep 24 13:05 libevent.so.3 -> /usr/pkg/emul/netbsd/lib/libevent.so.3
lrwxr-xr-x   1 root  wheel       40 Sep 24 13:05 libevent.so.3.2 -> /usr/pkg/emul/netbsd/lib/libevent.so.3.2
lrwxr-xr-x   1 root  wheel       36 Sep 24 13:05 liblzf.so.0 -> /usr/pkg/emul/netbsd/lib/liblzf.so.0
lrwxr-xr-x   1 root  wheel       38 Sep 24 13:05 liblzf.so.0.0 -> /usr/pkg/emul/netbsd/lib/liblzf.so.0.0
lrwxr-xr-x   1 root  wheel       37 Sep 24 13:05 libm.so.0.10 -> /usr/pkg/emul/netbsd/lib/libm.so.0.10
lrwxr-xr-x   1 root  wheel       40 Sep 24 13:05 libutil.so.7.19 -> /usr/pkg/emul/netbsd/lib/libutil.so.7.19
lrwxr-xr-x   1 root  wheel       40 Sep 24 20:48 libcrypto.so.12 -> /usr/pkg/emul/netbsd/lib/libcrypto.so.12
lrwxr-xr-x   1 root  wheel       42 Sep 24 20:48 libcrypto.so.12.0 -> /usr/pkg/emul/netbsd/lib/libcrypto.so.12.0
lrwxr-xr-x   1 root  wheel       37 Sep 24 20:48 libpcap.so.6 -> /usr/pkg/emul/netbsd/lib/libpcap.so.6
lrwxr-xr-x   1 root  wheel       39 Sep 24 20:48 libpcap.so.6.0 -> /usr/pkg/emul/netbsd/lib/libpcap.so.6.0

pbulk erases /usr/pkg, but doesn't clean up symlinks in /lib. It relies on the packages being
correct.

The symlinks are from compat packages, e.g. compat60 leaves the following symlinks:

lrwxr-xr-x   1 root  wheel       39 Dec 31 09:04 libc.so.12.181 -> /usr/pkg/emul/netbsd/lib/libc.so.12.181
lrwxr-xr-x   1 root  wheel       39 Dec 31 09:04 libedit.so.3.0 -> /usr/pkg/emul/netbsd/lib/libedit.so.3.0
lrwxr-xr-x   1 root  wheel       38 Dec 31 09:04 libevent.so.3 -> /usr/pkg/emul/netbsd/lib/libevent.so.3
lrwxr-xr-x   1 root  wheel       40 Dec 31 09:04 libevent.so.3.2 -> /usr/pkg/emul/netbsd/lib/libevent.so.3.2
lrwxr-xr-x   1 root  wheel       36 Dec 31 09:04 liblzf.so.0 -> /usr/pkg/emul/netbsd/lib/liblzf.so.0
lrwxr-xr-x   1 root  wheel       38 Dec 31 09:04 liblzf.so.0.0 -> /usr/pkg/emul/netbsd/lib/liblzf.so.0.0
lrwxr-xr-x   1 root  wheel       37 Dec 31 09:04 libm.so.0.10 -> /usr/pkg/emul/netbsd/lib/libm.so.0.10
lrwxr-xr-x   1 root  wheel       40 Dec 31 09:04 libutil.so.7.19 -> /usr/pkg/emul/netbsd/lib/libutil.so.7.19


>How-To-Repeat:
Run pbulk or install and remove compat packages.

>Fix:
Fix compat packages and make pbulk more aggressive when cleaning up a build host.

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.