Subject: core dumps on shutdown and more...
To: None <port-vax@netbsd.org>
From: Michael Kukat <michael@camaronet.de>
List: port-vax
Date: 06/06/1999 11:18:08
Hi !

I think i just found out where the core dumps of csh and inetd in the "halt"
process result from. Maybe this also is for the "shutdown" command, where
reboot and halt dums. (One tip here: If you use "halt&exit", you don't get
the usual dumps).

If you want to see a nice core dump, just try

od -x /netbsd | head

The last line should be "Broken pipe" or so, not "Segmentation fault". SIGPIPE
doesn't create these nice dumps. So i think there is a bug in signal handling.
This is what a ktrace of the above command does:

   191 od       RET   write 4096/0x1000
   191 od       CALL  write(0x1,0xb000,0x1000)
   191 od       PSIG  SIGPIPE caught handler=0x55555555 mask=() code=0x0
   191 od       RET   write -1 errno 32 Broken pipe
   191 od       PSIG  SIGSEGV SIG_DFL
   191 od       NAMI  "od.core"

Here you see, the SIGPIPE comes to the program, but i think, this handler
address looks a little bit strange... Is it an address ??? This all works
fine on the pmax port for example, tested with the same distribution on my
DECstation. So it must be a architecture-dependend bug, i think we should look
for it somewhere in VM routines.
I'll look into the sources, but if there is anyone more familiar with the
kernel internals, it would be nice to check this out. I need some time to
read into the common kernel tree how signal handling is done and where the bug
could come from.

so long... Michael