home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / sgi / 12634 < prev    next >
Encoding:
Text File  |  1992-08-19  |  1.8 KB  |  49 lines

  1. Newsgroups: comp.sys.sgi
  2. Path: sparky!uunet!charon.amdahl.com!pacbell.com!mips!odin!fido!agomoda!williams
  3. From: williams@agomoda.asd.sgi.com (Eric Williams)
  4. Subject: Re: Not enough swap space
  5. Message-ID: <oplo2uo@fido.asd.sgi.com>
  6. Sender: news@fido.asd.sgi.com (Usenet News Admin)
  7. Organization:  Silicon Graphics, Inc.  Mountain View, CA
  8. References: <7085@charon.cwi.nl>
  9. Date: Thu, 20 Aug 1992 00:29:57 GMT
  10. Lines: 37
  11.  
  12. In <7085@charon.cwi.nl> robertl@cwi.nl (Robert van Liere) writes:
  13.  
  14.  
  15. >A long, long time ago (i.e. in the 3.3.? days) Lance M Option @ NIH
  16. >wrote :
  17. >
  18. >>     SGI System Gurus:
  19. >>       We are experiencing problems with "malloc()".  It seems
  20. >>       that if an amount of memory greater than the sum of
  21. >>       free memory and free swap space is requested, the malloc()
  22. >>       succeeds, but the program is killed by the OS when the
  23. >>       memory is used.  How can this condition be caught?  Can't
  24. >>       the OS give some indication to the user of why his proc died?
  25. >
  26. >We are currently experiencing this behavior as well. Can this condition
  27. >be caught in 4.0.5 ? If not, is there something else we can do to avoid
  28. >these (SysV related) "problems".
  29.  
  30. I think the following should help.  It ought to change the behavior so that
  31. the malloc will fail.  The default as shipped is to have behavior as you
  32. describe.  (This change might also mean that processes are limited to total
  33. swap space, rather than the sum of swap space and physical memory.  Sorry
  34. I don't know for sure, so I can't say).
  35.  
  36. Edit /usr/sysgen/master.d/kernel:
  37.  
  38. /*
  39.  * preallocation of swap space
  40.  *      0  ==> disk space not preallocated for processes;
  41.  *      !0 ==> disk space preallocated on fork/exec/sbrk/etc.
  42.  */
  43. int availsmem_accounting = 0;
  44.  
  45.  
  46. Change the 0 to 1.  Run /etc/autoconfig.  Reboot.
  47.  
  48. -Eric Williams
  49.