home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.os.os2.advocacy:8532 comp.os.os2.misc:36790
- Path: sparky!uunet!ogicse!news.u.washington.edu!carson.u.washington.edu!tzs
- From: tzs@carson.u.washington.edu (Tim Smith)
- Newsgroups: comp.os.os2.advocacy,comp.os.os2.misc
- Subject: Re: OS/2 Crashproof? NOT!
- Message-ID: <1992Nov17.091742.6018@u.washington.edu>
- Date: 17 Nov 92 09:17:42 GMT
- Article-I.D.: u.1992Nov17.091742.6018
- References: <BxsoLo.qF@csfb1.fir.fbc.com> <1992Nov16.164438.27020@njitgw.njit.edu> <BxuC7D.9Bt@csfb1.fir.fbc.com>
- Sender: news@u.washington.edu (USENET News System)
- Organization: University of Washington School of Law, Class of '95
- Lines: 27
-
- In article <BxuC7D.9Bt@csfb1.fir.fbc.com> uunet!csfb1!jbrock writes:
- >|> This will kill any Unix system:
- >|>
- >|> while (1) fork();
- >|>
- >|> Such a thing can be done on most multitasking systems, and will kill
- >|> any OS that allows user-level processes to spawn child processes.
- >
- >I understand why unlimited forking will kill UNIX. What I don't
- >understand is why operating systems of more recent design don't protect
- >themselves from such obvious dangers. It doesn't seem that hard to me
- >conceptually. In the above example the forks should begin to fail
- >before they have eaten up all the resources that the operating system
- >needs to function. In other words, the operating system should reserve
- >sufficient resources to guarantee its own operation, and it should know
- >when it needs to begin turning down requests from resource hogs. Is
- >this really impossible?
-
-
- It's quite possible, and Unix has done it for several years. Only root
- can take the last process. In more modern versions of Unix, I'm pretty
- sure that there is a per ID limit on the number of processes.
-
- I'm not sure when the "only root can take the last process" came in,
- though. It wasn't in V6, but I think it was in 32V.
-
- --Tim Smith
-