public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Randy Dunlap <rdunlap@xenotime.net>
Cc: Jeremy Jackson <jerj@coplanar.net>, linux-kernel@vger.kernel.org
Subject: Re: signal to PID 1 from serial console like KeyboardRequest or CAD
Date: Thu, 31 Mar 2011 22:37:57 -0700	[thread overview]
Message-ID: <20110401053757.GA9866@core.coreip.homeip.net> (raw)
In-Reply-To: <20110331125706.9159a13d.rdunlap@xenotime.net>

On Thu, Mar 31, 2011 at 12:57:06PM -0700, Randy Dunlap wrote:
> On Fri, 25 Mar 2011 13:41:40 -0400 Jeremy Jackson wrote:
> 
> > Hi,
> > 
> > Sent to linux-console with no reply for over a week...
> > 
> > I ran into a problem recently on a Linux server with a remote serial 
> > console.  /sbin/init (actually Upstart) was in a state where nothing 
> > (useful) was running.  I had to power cycle the machine to get back to 
> > the boot prompt.  This has the side-effect of triggering raid rebuilds.
> > 
> > It would be nice to have what Ctrl-Alt-Del does at the VGA console with 
> > PS/2 or USB keyboard. This sends a SIGINT to PID 1, and most distros 
> > have this set to do "shutdown -r now" which attempts a clean reboot.
> 
> so C_A_D works at console via PS/2 or USB keyboard, but not on a remote
> serial console?  Could it be an issue with whatever remote/serial software
> you are using?

I believe it is simply a matter of console keymap and assigning "boot"
value to the desired combination.

> 
> > Once upon a time there was KeyboardRequest, which would send a SIGWINCH 
> > to PID 1 (when pressing Alt-UP_arrow?).  I don't see any sign of this 
> > feature in Linux 2.6.32 though.
> 
> I couldn't find it in 2.4.37 either.
> 
> Can 'loadkeys' help you any?
> 
> > Looking at the Sysrq handlers in the kernel I don't see any keystrokes 
> > that send SIGINT to PID 1 either.
> > 
> > So, I'm wondering if it makes sense to add a Sysrq key to send a signal 
> > to PID1 ?
> 
> Dmitry, any ideas?

We have SysRq bindings to unmount filesystems and reboot, isn't that
enough?

-- 
Dmitry

  reply	other threads:[~2011-04-01  5:38 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-25 17:41 signal to PID 1 from serial console like KeyboardRequest or CAD Jeremy Jackson
2011-03-31 19:57 ` Randy Dunlap
2011-04-01  5:37   ` Dmitry Torokhov [this message]
2011-04-01 15:39     ` Jeremy Jackson
2011-04-01 15:42       ` Randy Dunlap
2011-04-01 15:47         ` Jeremy Jackson
2011-04-01 15:59           ` Dmitry Torokhov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110401053757.GA9866@core.coreip.homeip.net \
    --to=dmitry.torokhov@gmail.com \
    --cc=jerj@coplanar.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rdunlap@xenotime.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox