Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!cmcl2!brl-adm!umd5!mimsy!arinc0!klt From: klt@arinc0.ARPA (Kermit Tensmeyer) Newsgroups: comp.unix.wizards Subject: Re: Setting process groups Message-ID: <766@arinc0.ARPA> Date: Mon, 7-Dec-87 13:58:02 EST Article-I.D.: arinc0.766 Posted: Mon Dec 7 13:58:02 1987 Date-Received: Sun, 13-Dec-87 07:23:21 EST References: <2990@hcr.UUCP> Reply-To: klt@arinc0.UUCP (Kermit Tensmeyer) Distribution: na Organization: ARINC Research Inc., Annapolis, MD Lines: 32 In article <2990@hcr.UUCP> larry@hcr.UUCP (Larry Philps) writes: > >Actually SVID setpgrp() has an "extra feature" that Berkeley setpgrp(getpid()) >does not have - it detaches the process from its controlling terminal. This >does tend to make it "difficult" to create a pipeline attached to your terminal >but with its own process group. > >Larry Philps That feature bit me in the rear. I have a process server that works to my satisfaction under BSD but attempting to convert it to SVID is danged near impossible. The server uses sockets to communicate with clients on the same hosts. These client are background processes that require terminal/console interaction with the operator (ie full screen interactions "mount tape for processing and tell which drive", or "Directory full - redirect message processing where?" etc.) The method under BSD is to set the process group that is allowed to access the current console to the master pid of the process which the system "thinks" currently own's the terminal. When processes do not have the terminal the server and associated code set the process group to zero. The upshot is that BSD allows any process with the "right" process id to interact on that terminal. (This is true esp. with c-shell) On the other hand SVID will let setpgrp be set to only zero and not the pid of any other process (regardless of the owner bit's). Is there a real workaround for a "pure" SVID environment? I can't test it in our "mongrel" mixed BSD/SVID (read Gould UTX) system. Kermit Tensmeyer klt@arinc-gw (26.2.0.88) (301) 266 2025