From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,d9086ce4afe48195 X-Google-Attributes: gid1164f8,public X-Google-Thread: f678f,d9086ce4afe48195 X-Google-Attributes: gidf678f,public X-Google-Thread: fee84,d9086ce4afe48195 X-Google-Attributes: gidfee84,public From: Drew Kramer Subject: Re: cron, inetd killed when other jobs use too much memory Date: 1996/09/23 Message-ID: <324717B7.1CFB@pa.dec.com>#1/1 X-Deja-AN: 184905623 references: <526c3p$re1@lion.embl-heidelberg.de> content-type: text/plain; charset=us-ascii organization: DEC Western Research Lab mime-version: 1.0 newsgroups: comp.sys.dec,comp.unix.osf.misc,comp.unix.osf.osf1 x-mailer: Mozilla 2.02 (X11; I; OSF1 V4.0 alpha) David Starks-Browning wrote: > > In Digital Unix 3.2C running on a an AlphaStation 250 4/266, occasionally > an application will consume excessive resources so that the system runs > out of virtual memory. > > Unfortunately, often the processes that are killed in this situation are > crucial daemons like inetd or cron. I understand the system's need to > kill processes to avoid crashing, but killing crucial processes like these > is not much better than crashing. > > It seems rather absurd to me that dU would kill cron or inetd rather than > a user application, preferably the one consuming too much memory. > > Is there some way to avoid this behavior? > > Thanks for your help. > > Sincerely, > David > > It seems to me that you should run swap in what I call eager allocation mode. If you have removed the /sbin/swapdefault link, put it back! This should be a symbolic link to your primary swap device. Here's mine: /sbin/swapdefault -> ../dev/rz0b If you don't have this link, when the system boots it will say: Sep 3 10:49:03 foo vmunix: vm_swap_init: warning /sbin/swapdefault swap device not found Sep 3 10:49:03 foo vmunix: vm_swap_init: swap is set to lazy (over commitment) mode This means you are in lazy (the opposite of eager) swap mode. In a nutshell, the difference is that in lazy mode, no swap is allocated until a proccess tries to swap or page. If a big fat process comes along, it is a random chance who gets nailed during a virtual memory starvation. In eager mode, the swap is allocated at the same time virutal memory is alocated. This means that if a process has a 32MB virtual size, then it will also "reserve" 32MB of swap space. This means that processes (like init or cron) will always be able to swap out successfully. The process that will die is the big fat one that is trying to pig up virtual memory. The consequence of running in eager mode is that you probably will have to configure more swap space, which you probably need to do anyway. -drew ------- Drew Kramer kramer@pa.dec.com "Welcome to the machine"