Viewing dmesg output after crash

Viewing dmesg output after crash

am 26.04.2011 11:48:21 von Amit Virdi

Hi

I'm debugging a system crash. I got OOPS message and found the buggy
piece of code. I wish I had the output of dmesg just before the crash.
In other words, I want to view the last messages collected by the ring
buffer used by dmesg.

The log messages are certainly being appended to some logfile in the
RAM. How can I find the address where the logfile is being created or
how can I extract the logfile?

Thanks n Regards
Amit Virdi
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

Re: Viewing dmesg output after crash

am 26.04.2011 11:59:43 von bradley

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Hi Amit,

Truly, the easiest thing you can do is connect to the console via serial
connection during boot and dump it that way.

The output you're getting from the boot probably isn't making it to
logfiles yet.

On 04/26/2011 02:48 AM, Amit Virdi wrote:
> Hi
>
> I'm debugging a system crash. I got OOPS message and found the buggy
> piece of code. I wish I had the output of dmesg just before the crash.
> In other words, I want to view the last messages collected by the ring
> buffer used by dmesg.
>
> The log messages are certainly being appended to some logfile in the
> RAM. How can I find the address where the logfile is being created or
> how can I extract the logfile?
>
> Thanks n Regards
> Amit Virdi
> --
> To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.linux-learn.org/faqs

- --
Bradley D. Thornton
Manager Network Services
NorthTech Computer
TEL: +1.760.666.2703 (US)
TEL: +44.203.318.2755 (UK)
http://NorthTech.US

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Find this cert at x-hkp://pool.sks-keyservers.net

iQEcBAEBAwAGBQJNtpePAAoJEE1wgkIhr9j323AIAJNey7bRf/fcwW5/sfMq pSJx
kNYxksD03CrwCCwClzOXInxnMqQxgrx9DGEqX2DotOVB8nvfrXK+gmM7aIvd yA3P
MtiYKuDNLHtNKKXcM5/I7SLZh4hbJCs9H5/GXALCeHtfYfpfwZe/+HnpSbbI 7Gkc
b3D2hANfvPJTLuv13l7j9kEx8PO4eBw5b17gh8jsG1HQUA7D1/BguIGQSpBi qowm
jdLMATQs6SU9WWDyQu9elGK1tKiWMMIIw/3O3c81VJU3fE0bY2q4EKySDkuD DHlF
pCg46AH6khq8N9qVaWLVikA9ebpTizaZRSRhNDPqewh/++H3buF3vOnmtWaD m1I=
=xEZF
-----END PGP SIGNATURE-----
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

Re: Viewing dmesg output after crash

am 26.04.2011 20:36:39 von Leo Prasath

I use netconsole which sends the kernel ring buffer updates to a
remote machine through UDP ..
And then you can use netcat command to dump the remote udp logs to a
file and view it.
I have never missed any log messages using this approach..

http://www.kernel.org/doc/Documentation/networking/netconsol e.txt

My commands are :

in the client machine ( which crashes ):

modprobe netconsole netconsole=3D@/eth0,@128.105.102.217/

where the ip address "128.105.102.217" is the remote machine's ip
address. ( which captures logs )

in the remote machine I run the command :

netcat -u -l -p 6666 | tee crashlog

also, iptables --flush helped me remove the udp packet filters which
sometimes can filter out the netconsole udp messages.

thanks,
-Leo



On Tue, Apr 26, 2011 at 4:48 AM, Amit Virdi wrote:
> Hi
>
> I'm debugging a system crash. I got OOPS message and found the buggy =
piece
> of code. I wish I had the output of dmesg just before the crash. In o=
ther
> words, I want to view the last messages collected by the ring buffer =
used by
> dmesg.
>
> The log messages are certainly being appended to some logfile in the =
RAM.
> How can I find the address where the logfile is being created or how =
can I
> extract the logfile?
>
> Thanks n Regards
> Amit Virdi
> --
> To unsubscribe from this list: send the line "unsubscribe linux-newbi=
e" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at =A0http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.linux-learn.org/faqs
>
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie"=
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs