NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Diagnosing cause of reboots



>   enough swap space, with the dp flag.    man swapctl
> 
>   enough space in /var to get the dump file back out.  run
>   /etc/rc.d/savecore manually immediately after the crash, and look if
>   it logged anything.  If there's a dump and no space, it will leave
>   it.   man savecore

Thanks for these pointers.  I think I've figured out why I have no core
files from the previous panics.  I actually don't have a "proper" swap
partition - there simply wasn't one included in the base NetBSD image
that my VPS provider (who, while being cool enough to *offer* NetBSD
images, I've come to realise are very inexperienced with setting up and
maintaining NetBSD systems).  So I use a swap file that lives on an FFS
filesystem.  This has worked fine so far and allowed me to do things
like system rebuilds which failed without, however it seems like swap
files cannot be used for dump space.  If I try to set one as such,
swapctl gives me back:

swapctl: could not set dump device to /swap_file_01: Block device
required

Which makes sense, I guess, as writing to a swap file must require
working filesystem code in the kernel, which has just paniced, whereas I
assume ordinary swap space partitions are just treated as unstructured
byte arrays like RAM and so require relatively little kernel
functionality to write to.

Oh well.  I've set ddb.on_panic=2, and used kern.panic_now=1 to
simulate a crash and then successfully gotten a backtrace through the
provider's serial console.  So hopefully if it happens again that will
give me enough information to go on.

Thanks very much for all your advice.

Luke



Home | Main Index | Thread Index | Old Index