lkml.org 
[lkml]   [1997]   [Jul]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: What to do on ctrl-alt-del?
Date
In article <Pine.LNX.3.95.970714145503.21268i-100000@Galois.fs100.suse.de>,
Hubert Mantel <mantel@suse.de> wrote:
>Hi,
>
>if you call reboot(2) to disable ctrl-alt-del, SIGINT will be sent to
>process 1 if the user presses ctrl-alt-del. This has been ok in the past
>but since Linux has the unique initrd feature there is not always a
>process with pid 1.

Why? Init is special in more ways then that one. For example, there should
always be a process with pid 1, that adopts the processes without a parent
and does a wait() to clean up after they die. Also, you can't kill process
#1 with -STOP or -KILL.

>As initrd is intended and used for installation
>purposes it might be necessary to allow linuxrc to intercept ctr-alt-del;
>otherwise the system immediately reboots upon that key combination without
>a clean shutdown. Wouldn't it be correct to send SIGINT to the process
>that disabled ctrl-alt-del?

I don't think so since that makes the "ctrlaltdel" utility pretty useless.

How do you manage to end up without a process #1 anyway?

Mike.
--
| Miquel van Smoorenburg | "I need more space" "Well, why not move to Texas" |
| miquels@cistron.nl | "No, on my account, stupid." "Stupid? Uh-oh.." |
| PGP fingerprint: FE 66 52 4F CD 59 A5 36 7F 39 8B 20 F1 D6 74 02 |

\
 
 \ /
  Last update: 2005-03-22 13:39    [W:1.081 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site