How to printk synchronously

Valdis Kl=?utf-8?Q?=c4=93?=tnieks valdis.kletnieks at vt.edu
Wed Nov 27 04:18:00 EST 2019


On Tue, 26 Nov 2019 22:31:08 +0000, Lucas Tanure said:
> Hi,
>
> What about ftrace ? Documentation/trace/ftrace.txt

That won't help - his ^@^@^@ is a result of the system stopping and no longer
writing to disk, so his logfile has blocks allocated to it but not yet written
to.

Using ftrace will have the same problem, if his kernel is locking up and not
syncing to disk.

A better approach would be to use netconsole to send all the console output to
another machine, or serial console if that's an option.

Though I have to wonder how he's determining it's a deadlock issue rather than
a panic that's just plain stopping the system - building the kernel with
lockdep support should reveal the issue before a lockup. And if it *is* a
deadlock, there should be sufficient info in the watchdog logging (assuming the
hardware has some sort of watchdog support, as most systems do).

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20191127/ed180f2b/attachment.sig>


More information about the Kernelnewbies mailing list