Bug 104912 - RFE: would like echo p > /proc/sysrq-trigger to show registers
RFE: would like echo p > /proc/sysrq-trigger to show registers
Product: Red Hat Enterprise Linux 2.1
Classification: Red Hat
Component: kernel (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: dff
Brian Brock
: FutureFeature
Depends On:
  Show dependency treegraph
Reported: 2003-09-23 10:59 EDT by David Truchan
Modified: 2007-11-30 17:06 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-05-04 16:53:30 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description David Truchan 2003-09-23 10:59:57 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)

Description of problem:
Is it possible to get echo p > /proc/sysrq-trigger to show registers.

I opened a call with RedHat support on this and they told me to 
submit a RFE (Request for Enhancement) on bugzilla. 

Basicall, echo m > /proc/sysrq-trigger works as well as
echo t > /proc/sysrq-trigger.   However, echo p > /proc/sysrq-trigger
does not work.  Many times when I call redhat support, they ask for
the output of this syrq "p" trigger.  

It would be handy if you could do this remotely or from a script instead of 
having to be sitting in front of the console and hitting
the <alt> <sysrq> keys.  

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. echo 1 > /proc/sys/kernel/sysrq
2. echo p > /proc/sysrq-trigger 

Actual Results:  dmesg and /var/log/messages show this line:
SysRq: Show Regs 

That's it nothing else is printed.  If you go to console and
hit <alt> <sysrq> <p> than registers get dumped.

Expected Results:  Expect registers to get dumped.

Additional info:

Tested this on e.24, e.27 and beta Linux Enterprise 3 kernel.
Comment 2 Rik van Riel 2003-09-23 16:19:11 EDT
If "echo p > /proc/sysrq-trigger" dumps the registers, you are almost certain to
see a process in the middle of sys_write(2), to a file in /proc. More precisely,
it'll be writing to /proc/sysrq-trigger.

I'm not sure how dumping that info would be very useful, since you know what's
happening on your cpu when you echo something to /proc/sysrq-trigger ...

However, let me know if I've overlooked something (I wouldn't be surprised).
Comment 3 David Truchan 2003-09-23 21:49:26 EDT
You bring up a good point, if the only info you'll gather is capturing a  
syswrite from the "echo p" process, than I guess that doesn't make a whole lot 
of sense.

Is there any way to dump the regs remotely if you're not in front of the 

Comment 4 Rik van Riel 2003-09-23 22:57:50 EDT
Over serial console you can trigger sysrq commands.

By default you need to send a break, followed by the sysrq letter.

In /proc/sys/kernel/sysrq-key you can configure another special key, which is
useful if your terminal program doesn't want to send a break.
Comment 5 Suzanne Hillman 2005-05-04 16:53:30 EDT
Closing as this appears to be resolved.

Note You need to log in before you can comment on or make changes to this bug.