Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 07 Apr 2024 08:59:19 +0000
From:      bugzilla-noreply@freebsd.org
To:        pkg@FreeBSD.org
Subject:   [Bug 278190] ports-mgmt/pkg: 1.21.0 pkg-static core dumps
Message-ID:  <bug-278190-32340-eiI003vz7x@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-278190-32340@https.bugs.freebsd.org/bugzilla/>
References:  <bug-278190-32340@https.bugs.freebsd.org/bugzilla/>

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

O. Hartmann <ohartmann@walstatt.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|Not A Bug                   |---
            Summary|ports-mgmt/pkg: 1.21.0      |ports-mgmt/pkg: 1.21.0
                   |renders core dumps on some  |pkg-static core dumps
                   |ports                       |
             Status|Closed                      |Open

--- Comment #2 from O. Hartmann <ohartmann@walstatt.org> ---
After rebuilding ports-mgmt/pkg via "portmaster -df ports-mgmt/pkg"  alongs=
ide
with sqlite3 and rebuilding the OS (FreeBSD 15.0-CURRENT #0
main-n269169-0192eda105b3: Sun Apr  7 02:08:57 CEST 2024 amd64) from scratch
after import of LLVM18, the reported problem isn't gone.

There are more ports affected, I hit them by chance, like

www/apache24
databases/redis
net/openldap26-server
misc/e2fsprogs-libuuid

The problem isn't specifically to a single host, it is common on several bo=
xes
running CURRENT. I also saw this issue after updating pkg from 1.20.9_1 ->
1.21.0 on a 14-STABLE at the lab.

Phenomenon: Neither portmaster nor traditional "make" does work properly: i=
f a
port is to be updated, deleting the old port in favor to be updated with the
new port fails and pkg-static dumps a core.

Last port which triggered this misbehaviour was=20
 misc/e2fsprogs-libuuid

I had to patch the port's Makefile first to apply "${SETENVI} ${MAKE_ENV}" =
to
build-tags to make the port build again (there is an error when using
portmaster for ports utilizing gmake). But this is just for the record.

My skills debugging with LLVM aren't much, I tried to use gdb on the core f=
ile:

[...]
 gdb  /usr/local/sbin/pkg-static  ./packages/portmaster-backup/pkg-static.c=
ore
GNU gdb (GDB) 14.1 [GDB v14.1 for FreeBSD]
Copyright (C) 2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.htm=
l>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-portbld-freebsd15.0".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/local/sbin/pkg-static...
(No debugging symbols found in /usr/local/sbin/pkg-static)
[New LWP 101269]
Core was generated by `/usr/local/sbin/pkg-static delete -yf
e2fsprogs-libuuid-1.47.0'.
Program terminated with signal SIGSEGV, Segmentation fault.
Address not mapped to object.
#0  0x0000(gdb) run
Starting program: /usr/local/sbin/pkg-static=20
/usr/ports/devel/gdb/work-py39/gdb-14.1/gdb/fbsd-nat.c:1381: internal-error:
wait_1: Assertion `fbsd_inf !=3D nullptr || pl.pl_flags & PL_FLAG_CHILD' fa=
iled.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
----- Backtrace -----
0x134f5f1 _Z22gdb_internal_backtracev
0x17ff7e8 ???
0x17ff648 _Z15internal_verrorPKciS0_P13__va_list_tag
0x1ca94ae _Z18internal_error_locPKciS0_z
0x148bf53
_ZN15fbsd_nat_target6wait_1E6ptid_tP17target_waitstatus10enum_flagsI16targe=
t_wait_flagE
0x148c67a
_ZN15fbsd_nat_target4waitE6ptid_tP17target_waitstatus10enum_flagsI16target_=
wait_flagE
0x17a0373
_Z11target_wait6ptid_tP17target_waitstatus10enum_flagsI16target_wait_flagE
0x15d31c9
_Z16startup_inferiorP22process_stratum_targetiiP17target_waitstatusP6ptid_t
0x1497721 _Z20gdb_startup_inferiorii
0x14f9ed1
_ZN17inf_ptrace_target15create_inferiorEPKcRKNSt3__112basic_stringIcNS2_11c=
har_traitsIcEENS2_9allocatorIcEEEEPPci
0x148ce51
_ZN15fbsd_nat_target15create_inferiorEPKcRKNSt3__112basic_stringIcNS2_11cha=
r_traitsIcEENS2_9allocatorIcEEEEPPci
0x1506690 ???
0x13838b5 _Z8cmd_funcP16cmd_list_elementPKci
0x17ca082 _Z15execute_commandPKci
0x146fe2a _Z15command_handlerPKc
0x14701b5
_Z20command_line_handlerONSt3__110unique_ptrIcN3gdb13xfree_deleterIcEEEE
0x146f822 ???
0x825a926b2 rl_callback_read_char
0x1470c0d ???
0x146f47c ???
0x17fe6ef ???
0x1ca9f12 ???
0x1ca99e4 _Z16gdb_do_one_eventi
0x15758d9 ???
0x1572ac0 _Z8gdb_mainP18captured_main_args
0x124f5e0 main
---------------------
/usr/ports/devel/gdb/work-py39/gdb-14.1/gdb/fbsd-nat.c:1381: internal-error:
wait_1: Assertion `fbsd_inf !=3D nullptr || pl.pl_flags & PL_FLAG_CHILD' fa=
iled.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
000000b3de2b in strlen_baseline ()
[...]

So, according to the output of gdb, this is no information at all since gdb
crashes somehow.

Need some advice how to proceed.

--=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-278190-32340-eiI003vz7x>