From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,c6c50696a98e1b35 X-Google-Attributes: gidfee84,public From: Bill Reid Subject: Re: why my swap space run low? Date: 1996/06/27 Message-ID: <31D30FB4.41C6@wil.lad.gmeds.com>#1/1 X-Deja-AN: 162456100 references: <4qqbsf$10ap@ctsc.hkbc.hk> content-type: text/plain; charset=us-ascii organization: EDS mime-version: 1.0 newsgroups: comp.unix.osf.osf1 x-mailer: Mozilla 2.0 (X11; I; OSF1 V3.0 alpha) Wong Pui Ming wrote: > > lately our osf1 (ver 3.0) always got the message > swap space is low. But in fact there are not too many processses > running. I did the swapon -s to see, and got the following > Could some spot what's going on for me please ? > > Swap partition /dev/rz0b (default swap): > Allocated space: 25088 pages (196MB) > In-use space: 4224 pages ( 16%) > Free space: 20864 pages ( 83%) > > Swap partition /dev/rz2b: > Allocated space: 25088 pages (196MB) > In-use space: 4074 pages ( 16%) > Free space: 21014 pages ( 83%) > > Total swap allocation: > Allocated space: 50176 pages (392MB) > Reserved space: 44173 pages ( 88%) > In-use space: 8298 pages ( 16%) > Available space: 6003 pages ( 11%) Check and see what type of swapping you are doing. Read the man page on swapon. If you have a soft link named /sbin/swapdefault then the system reserves space every time modifiable virtual address space is created. Try doing a ps auwx |more. Look under the columns VSZ and RSS. The VSZ is the amount of virtual address space created when the process starts. The RSS is the real memory being used. If you look at your processes you may find some like terminals or xdm sessions which ask for VSZ of 3-6M but are only using a few K. If you have many of these processes the system is reserving space incase it is needed but not letting any other process use that space. If this is the case you may want to switch to the deferred method of swapping. You will need to mv /sbin/swapdefault or delete it and then reboot your system. What will happen is that the system will no longer reserve swap space but will just take what it needs. The drawback to this method is if the system is busy and needs swap space that it can not get it will start to kill processes to free up space. We are currently running two systems this way and have had little problems. Hope this helps. Bill Reid Advanced Software SE EDS Wilmington Assembly