Re: savecore: BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276

2018-10-25 Thread John Baldwin
On 10/25/18 2:14 AM, Marcin Cieslak wrote:
> On Wed, 24 Oct 2018, John Baldwin wrote:
> 
>> On 10/23/18 10:58 AM, Marcin Cieslak wrote:
>>> This GDB was configured as "amd64-marcel-freebsd"...BFD: 
>>> /boot/kernel/kernel: invalid relocation type 37
>>> BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail 
>>> /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276
>>>
>>> The kernel has been built on 11.1 with LD=/usr/bin/ld.lld
>>>
>>> Is this something that matters at all?
>>
>> It is not something that is likely to be fixed.  If you pkg install gdb from
>> ports, is the kgdb it includes able to examine the crash dump?
> 
> Not really (using 8.2 from ports):
> 
> # /usr/local/bin/kgdb82 -n 5 /usr/obj/usr/src/sys/GENERIC/kernel.debug
> GNU gdb (GDB) 8.2 [GDB v8.2 for FreeBSD]
> Copyright (C) 2018 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later 
> 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-freebsd11.1".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> .
> Find the GDB manual and other documentation resources online at:
> .
> 
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from /usr/obj/usr/src/sys/GENERIC/kernel.debug...done.
> thread.c:93: internal-error: struct thread_info *inferior_thread(): Assertion 
> `tp' failed.
> A problem internal to GDB has been detected,
> further debugging may prove unreliable.
> Quit this debugging session? (y or n) 

This usually means the kernel image you are using doesn't match the vmcore, so
it's reading garbage data from the vmcore since the symbol offsets are wrong.

You can test this by doing what crashinfo does: compare the version string in 
the
/var/crash/info.5 file with 'p version' in kgdb (or gdb) of the kernel without
a vmcore.

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: savecore: BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276

2018-10-25 Thread Marcin Cieslak
On Wed, 24 Oct 2018, John Baldwin wrote:

> On 10/23/18 10:58 AM, Marcin Cieslak wrote:
> > This GDB was configured as "amd64-marcel-freebsd"...BFD: 
> > /boot/kernel/kernel: invalid relocation type 37
> > BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail 
> > /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276
> > 
> > The kernel has been built on 11.1 with LD=/usr/bin/ld.lld
> > 
> > Is this something that matters at all?
> 
> It is not something that is likely to be fixed.  If you pkg install gdb from
> ports, is the kgdb it includes able to examine the crash dump?

Not really (using 8.2 from ports):

# /usr/local/bin/kgdb82 -n 5 /usr/obj/usr/src/sys/GENERIC/kernel.debug
GNU gdb (GDB) 8.2 [GDB v8.2 for FreeBSD]
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
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-freebsd11.1".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
.
Find the GDB manual and other documentation resources online at:
.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/obj/usr/src/sys/GENERIC/kernel.debug...done.
thread.c:93: internal-error: struct thread_info *inferior_thread(): Assertion 
`tp' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) 

With regular base kgdb I can open it but I can't get any backtrace or anything:

Cannot access memory at address 0x0
(kgdb) info reg
rax0x0  0
rbx0x0  0
rcx0x0  0
rdx0x0  0
rsi0x0  0
rdi0x0  0
rbp0x0  0x0
rsp0x0  0x0
r8 0x0  0
r9 0x0  0
r100x0  0
r110x0  0
r120x0  0
r130x0  0
r140x0  0
r150x0  0
rip0x0  0
eflags 0x0  0
cs 0x0  0
ss 0x0  0
ds 0x0  0
es 0x0  0
fs 0x0  0
gs 0x0  0

What should I try next? at what stage is bfd involved in the savecore process?

Marcin


smime.p7s
Description: S/MIME Cryptographic Signature


Re: savecore: BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276

2018-10-24 Thread John Baldwin
On 10/23/18 10:58 AM, Marcin Cieslak wrote:
> Hello, I have a freshly built 12.0-ALPHA10 (r339406) and the kernel
> panicked at some point (another mail coming on that).
> 
> I have a full dump partition enabled, but during savecore
> quite lot BFD assertion messages appear:
> 
> Tue Oct 23 18:45:53 CEST 2018
> 
> FreeBSD radziecki 12.0-ALPHA10 FreeBSD 12.0-ALPHA10 r339406 GENERIC  amd64
> 
> panic: 
> 
> GNU gdb 6.1.1 [FreeBSD]
> Copyright 2004 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you are
> welcome to change it and/or distribute copies of it under certain conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for details.
> This GDB was configured as "amd64-marcel-freebsd"...BFD: /boot/kernel/kernel: 
> invalid relocation type 37
> BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail 
> /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276
> 
> The kernel has been built on 11.1 with LD=/usr/bin/ld.lld
> 
> Is this something that matters at all?

It is not something that is likely to be fixed.  If you pkg install gdb from
ports, is the kgdb it includes able to examine the crash dump?

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


savecore: BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276

2018-10-23 Thread Marcin Cieslak
Hello, I have a freshly built 12.0-ALPHA10 (r339406) and the kernel
panicked at some point (another mail coming on that).

I have a full dump partition enabled, but during savecore
quite lot BFD assertion messages appear:

Tue Oct 23 18:45:53 CEST 2018

FreeBSD radziecki 12.0-ALPHA10 FreeBSD 12.0-ALPHA10 r339406 GENERIC  amd64

panic: 

GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "amd64-marcel-freebsd"...BFD: /boot/kernel/kernel: 
invalid relocation type 37
BFD: BFD 2.17.50 [FreeBSD] 2007-07-03 assertion fail 
/usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf64-x86-64.c:276

The kernel has been built on 11.1 with LD=/usr/bin/ld.lld

Is this something that matters at all?

Marcin


smime.p7s
Description: S/MIME Cryptographic Signature