Skip to contentSkip to conversation

Netconsole and logging everything from /dev/console

DISCUSSION Martin Michlmayr 2 participants 3 messages Nov 16, 2007 – Nov 17, 2007

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

I'm supporting a number of consumer devices (e.g. small NAS devices) in Debian. They typically don't export the serial console and don't have any other output devices. We perform the installation via SSH on such devices and start SSH automatically when the system boots so people can login. This works pretty well but sometimes a device stops to boot for no good reason. This is usually really hard to debug since we don't have any logs at all.

I could activate netconsole in order to see kernel messages but then I still wouldn't see anything that's printed by the ramdisk and later when services are started. Ideally, I'd like to have an option for netconsole to show every message that is also shown on the console.

Do you think that would be possible?

Signature · 2 lines
Martin Michlmayr
http://www.cyrius.com/
#1 lore raw
Quoted 8 lines · Martin Michlmayr

I'm supporting a number of consumer devices (e.g. small NAS devices) in Debian. They typically don't export the serial console and don't have any other output devices. We perform the installation via SSH on such devices and start SSH automatically when the system boots so people can login. This works pretty well but sometimes a device stops to boot for no good reason. This is usually really hard to debug since we don't have any logs at all.

Quoted 6 lines

I could activate netconsole in order to see kernel messages but then I still wouldn't see anything that's printed by the ramdisk and later when services are started. Ideally, I'd like to have an option for netconsole to show every message that is also shown on the console.

Do you think that would be possible?

It is, definitely, you just need to wire up a tty struct's write method to netconsole's and add it to the console registration. But I haven't had any time to work on this in a while.

Signature · 1 line
Mathematics is the supreme nostalgia of our time.
#2 lore raw
Quoted 5 lines · Matt Mackall
Quoted 1 line

Do you think that would be possible?

It is, definitely, you just need to wire up a tty struct's write method to netconsole's and add it to the console registration. But I haven't had any time to work on this in a while.

Where would I look for examples I could follow?

Signature · 2 lines
Martin Michlmayr
http://www.cyrius.com/