Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83 (MC840302); site ttds.UUCP Path: utzoo!linus!philabs!cmcl2!seismo!mcvax!enea!ttds!johanw From: johanw@ttds.UUCP (Johan Wide'n) Newsgroups: net.bugs.2bsd Subject: Re: Inexplicable 2.9BSD crashes (more info) Message-ID: <965@ttds.UUCP> Date: Fri, 31-May-85 13:10:45 EDT Article-I.D.: ttds.965 Posted: Fri May 31 13:10:45 1985 Date-Received: Sun, 2-Jun-85 20:15:52 EDT References: <1154@uwmacc.UUCP> Reply-To: johanw@ttds.UUCP (Johan Wide'n) Distribution: net Organization: The Royal Inst. of Techn., Stockholm Lines: 93 One thing too watch out for is a bad /etc/init. /etc/init as delivered to us did not reset several signals before execing other programs. This bug was pointed out by (ihnp4!inuxc!isrnix!greg) >Received: by isrnix.UUCP; Wed, 13 Jun 84 18:03:38 EST >To: BERKELEY!2bsd-people >Subject: 2.9 problem > > > I'm having a problem with 2.9 - I am getting spurious signals sent >to all the processes - the signal is signal 9 (I'm almost sure) and >init (proc 1) does not get it (although everything else does). Has >anyone else seen this? I have VFORK and MENLO_JCL turned on f.y.i. >Any ideas? --------------- >Received: by isrnix.UUCP; Thu, 14 Jun 84 18:11:15 EST >To: BERKELEY!2bsd-people >Subject: My earlier message about interrupts. > > > Found the culprit - > > There is a bug in our distributed version of init.c. In dofork and >runcom you should add the signal calls > > signal(SIGINT, DIG_DFL); > and > signal(SIGTERM, SIG_DFL); > >Greg So: check out your /usr/src/cmd/init.c. Here is a context diff: *** init.c.org Wed May 18 20:54:04 1983 --- init.c Fri Apr 26 16:13:28 1985 *************** *** 201,206 pid = fork(); if(pid == 0) { open("/", 0); dup(0); dup(0); --- 201,208 ----- pid = fork(); if(pid == 0) { + signal(SIGTERM, SIG_DFL); + signal(SIGINT, SIG_DFL); open("/", 0); dup(0); dup(0); *************** *** 205,210 dup(0); dup(0); #ifdef UCB_AUTOBOOT if ((howto & RB_SINGLE) || (howto & RB_NOFSCK)) arg1 = "fastboot"; else --- 207,213 ----- dup(0); dup(0); #ifdef UCB_AUTOBOOT + signal(SIGQUIT, SIG_DFL); if ((howto & RB_SINGLE) || (howto & RB_NOFSCK)) arg1 = "fastboot"; else *************** *** 413,418 pid = fork(); if(pid == 0) { signal(SIGTERM, SIG_DFL); signal(SIGHUP, SIG_IGN); strcpy(tty, dev); strncat(tty, p->line, LINSIZ); --- 416,425 ----- pid = fork(); if(pid == 0) { signal(SIGTERM, SIG_DFL); + signal(SIGINT, SIG_DFL); + #ifdef UCB_AUTOBOOT + signal(SIGQUIT, SIG_DFL); + #endif signal(SIGHUP, SIG_IGN); strcpy(tty, dev); strncat(tty, p->line, LINSIZ); johanw@ttds Johan Widen