Debugging signal 11

Ian Lepore ian at freebsd.org
Sun Apr 18 19:18:04 UTC 2021


On Sun, 2021-04-18 at 15:53 -0300, Lucas Nali de Magalhães wrote:
> This also isn't the usual. Debugging a running process is possible but
> the process you used is the wrong one. Debugging init, OTOH, is a
> completely different story: init is the first process and is the most
> important process of any unix. The actual command varies from
> debugger to debugger but in gdb, "attach pid"  may do the trick for
> you. You will need to be extra cautious because of you are aiming init.
> Ideally, init is the process supposed to catch the signals and keep
> the system running. So a break into it may cause your system to crash.

Given that it is init that is segfaulting, how to you propose that the
OP lauch gdb in order to do an attach to init?  In other words: there
is a reason the OP is trying to use the kernel debugger to examine
what's going on here.

-- Ian




More information about the freebsd-hackers mailing list