2009-01-10 19:13:21

by Hans de Bruin

[permalink] [raw]
Subject: Kernelmessage to usbstick?

Would it be possible to send kernel messages to an usbstick? On poweroff
my laptop displays a kernel trace and a final message:
poweroff[3114] exited with preempt_count 2
/etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
I don't have a serial cable within reach, but plenty of usbsticks.

--
Hans


2009-01-10 22:53:51

by Andi Kleen

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

Hans de Bruin <[email protected]> writes:

> Would it be possible to send kernel messages to an usbstick? On
> poweroff my laptop displays a kernel trace and a final message:
> poweroff[3114] exited with preempt_count 2
> /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
> I don't have a serial cable within reach, but plenty of usbsticks.

There's a mtdoops.c indeed, but it currently only works on
MTD controlled flash devices, not usb sticks.

However usb sticks would need the USB subsystem to be running and it's
unlikely that will be the case really late in poweroff. So it might
not help.

-Andi

--
[email protected]

2009-01-10 22:57:49

by Oliver Neukum

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

Am Saturday 10 January 2009 23:53:15 schrieb Andi Kleen:
> Hans de Bruin <[email protected]> writes:
>
> > Would it be possible to send kernel messages to an usbstick? On
> > poweroff my laptop displays a kernel trace and a final message:
> > poweroff[3114] exited with preempt_count 2
> > /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
> > I don't have a serial cable within reach, but plenty of usbsticks.
>
> There's a mtdoops.c indeed, but it currently only works on
> MTD controlled flash devices, not usb sticks.
>
> However usb sticks would need the USB subsystem to be running and it's
> unlikely that will be the case really late in poweroff. So it might
> not help.

USB in turn needs PCI, interrupts and DMA.

Regards
Oliver

2009-01-11 13:31:27

by Hans de Bruin

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

Oliver Neukum wrote:
> Am Saturday 10 January 2009 23:53:15 schrieb Andi Kleen:
>> Hans de Bruin <[email protected]> writes:
>>
>>> Would it be possible to send kernel messages to an usbstick? On
>>> poweroff my laptop displays a kernel trace and a final message:
>>> poweroff[3114] exited with preempt_count 2
>>> /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
>>> I don't have a serial cable within reach, but plenty of usbsticks.
>> There's a mtdoops.c indeed, but it currently only works on
>> MTD controlled flash devices, not usb sticks.
>>
>> However usb sticks would need the USB subsystem to be running and it's
>> unlikely that will be the case really late in poweroff. So it might
>> not help.
>
> USB in turn needs PCI, interrupts and DMA.
>

I just found out even a serial cable would not help, since the only comm
device in my laptop ends in a build in modem. Since there is no parallel
printer port either I will have to use pen and paper. In the mean time,
rc1 broke my keyboard.

--
Hans

2009-01-11 18:07:48

by Mark Lord

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

Oliver Neukum wrote:
> Am Saturday 10 January 2009 23:53:15 schrieb Andi Kleen:
>> Hans de Bruin <[email protected]> writes:
>>
>>> Would it be possible to send kernel messages to an usbstick? On
>>> poweroff my laptop displays a kernel trace and a final message:
>>> poweroff[3114] exited with preempt_count 2
>>> /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
>>> I don't have a serial cable within reach, but plenty of usbsticks.
>> There's a mtdoops.c indeed, but it currently only works on
>> MTD controlled flash devices, not usb sticks.
>>
>> However usb sticks would need the USB subsystem to be running and it's
>> unlikely that will be the case really late in poweroff. So it might
>> not help.
>
> USB in turn needs PCI, interrupts and DMA.
..

Dunno about an oops, but I currently use a USB device to
display debug messages from the shutdown procedure,
all the way to kernel_halt().

So long as the Oops doesn't kill too much low level stuff,
it's probably feasible. Except for the very slow write times
for many USB storage devices.

2009-01-13 21:31:20

by Hans de Bruin

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

Hans de Bruin wrote:
> Would it be possible to send kernel messages to an usbstick? On poweroff
> my laptop displays a kernel trace and a final message:
> poweroff[3114] exited with preempt_count 2
> /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
> I don't have a serial cable within reach, but plenty of usbsticks.
>

The shutdown problem just disappeared.

--
Hans

2009-01-18 08:22:22

by Pavel Machek

[permalink] [raw]
Subject: Re: Kernelmessage to usbstick?

On Sat 2009-01-10 20:13:10, Hans de Bruin wrote:
> Would it be possible to send kernel messages to an usbstick? On poweroff
> my laptop displays a kernel trace and a final message:
> poweroff[3114] exited with preempt_count 2
> /etc/rc.d/rc.0: line 265: 3114 Segementation fault /sbin/poweroff.
> I don't have a serial cable within reach, but plenty of usbsticks.

digital camera :-).

...or green display with *long* phosphor burn time.
Pavel

--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html