From: jh@cadre.com (Joe Hartley)
Newsgroups: comp.sys.sun.admin
Subject: Re: Size of swap file
Date: 8 Oct 92 12:41:38 GMT
Article-I.D.: fripp.1992Oct8.124138.14696
Reply-To: jh@cadre.com
Organization: Cadre Technologies, Inc.

In article 92Oct7162852@ra.cs.umb.edu, rouilj@cs.umb.edu (John P. Rouillard) writes:
>
>In article <1992Oct7.132659.6926@fripp.ri.cadre.com>  jh@cadre.com 
>	(Joe Hartley) writes:
>
>>   Now, considering that I can't dynamically allocate swap space from the 
>>   free space on my hard drive, and that I'm only going to determine the
>
>Maybe not dynamically, but adding swap FILES can help a lot, and it is
>certianly more dynamic that adding a swap partition.

I have done this, and use this method when I add RAM to a system.  When I
said "I can't dynamically allocate swap space", I meant that the OS isn't
going to automatically allocate more space if it's running out of swap.
There's an upper limit that's defined and must be manually set, and if
it isn't large enough, you're straight out of luck until you do the
mkfile/swapon shuffle.

>
>>   amount of disk space to allocate to swap when I'm a) setting up a new
>>   machine or b) adding RAM, how should I make such am decision at that
>>   time?  I've always found the RAM x 2 formula to be a great rule of thumb
>>   for determining such things.
>
>>   How would *you* determine the swap area at setup time?
>
>
>I wouldn't. I would allocate just as much as was needed for memory,
>then use mkfile and swapon to add more if necessary. When it came time
>to upgrade the system or otherwise screw around with disk space etc, I
>would add up all of the swap files that I have and add that size swap
>partition if I find too much space wasted in swap files (usually
>greater than 1/4 to 1/2 of my original swap partition), I would add a
>new swap partition of that size, since swap files don't perform as
>well as swap partitions. Granted none of this works if you don't have
>SunOS, but then again this is comp.sys.sun.
>
>Anyway, I have spent time optimizing the available disk space/swap
>space on systems my users use as their job loads change. Just part of
>the job of doing system administration.
>
>-- John

Unfortunately, since system administration is not my primary job, I don't
have time to monitor the 15 or so machines on my net for optimum swap.
In a perfect world, I'd have the time to do so, but I'm more interested
in getting the machine up and having it run with a minimum of maintenance.
And since my users aren't engineers but accountants and administrators,
having the users monitor their own swap space is unrealistic.

You might not agree with my rule of thumb, but as I said, it works well 
enough in this situation.


---
===============================================================================
Joe Hartley          | jh@cadre.com  -  Whenever you find that you are on the
Cadre Technologies   | side of the majority, it is time to reform. - M. Twain
222 Richmond St.     | --------------------------------------------------------
Providence, RI 02903 | Overman 1st Class - the Kilgore Trout Memorial Clench
(401) 351-5950 x266  |            of the Church of the SubGenius  
===============================================================================