Re: Swap size

2007-08-17 Thread Andy Greenwood

Jerry McAllister wrote:

On Fri, Aug 17, 2007 at 02:05:57AM +0200, Nicholas Wieland wrote:

  
I was reading tuning(7), and I found that I should size my swap  
double the size of my physical memory.
AFAIK that was true some years ago, when memory was not as cheap as  
now, and following that guideline I should set my swap to 2GB, which  
seems far too much for swap (at least to me ...). I will never need  
this much memory as 1GB RAM and 2GB swap.
Is it still correct ? How can I resize with bsdlabel if I already  
used all my disk space during install ?



Remember, disk sizes have shot up too.
No, 2 GB is not excessive.   You can get by with less, but you're
not likely to be using proportionately as much disk now as you used
to by going with 2X - I aim for a little over 2X.

Remember that swap gets used for crash dumps and also for paging.
Now, you may think that you want to keep your machine from paging 
and in one sense that is true.   If you are so memory bound that
it has to page just to run, you're going to be so slow that it 
seems to have froze (by today's standards).   But, the system does

write stuff to page space and for processes that are often called
it can speed things up.  


So, it is not really a waste to assign that much to swap.

jerry

  

TIA,
  ngw

--
Nicholas Wieland
[EMAIL PROTECTED]



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]
  
My understanding was that you should estimate swap size based on the 
sizes of the programs which might be paged out. However, when I first 
set up my system, I didn't know this and created 1G swap slices (one on 
each disk) but I am not convinced that this was the best thing to do, 
since my system almost never uses a noticible percentage of the swap 
space. right now, I've got


[EMAIL PROTECTED] fusefs-sshfs]$ swapinfo
Device  1K-blocks UsedAvail Capacity
/dev/ad0s1b.eli   1048576 1148  1047428 0%
/dev/ad1s1b.eli   1048576 1096  1047480 0%
Total 2097152 2244  2094908 0%

And the system is under normal load. This system has 1G of RAM. Is there 
any sense in having this much swap space when it's not being used?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-08-17 Thread Paul Schmehl
--On Friday, August 17, 2007 11:07:14 -0400 Andy Greenwood 
[EMAIL PROTECTED] wrote:



Jerry McAllister wrote:

On Fri, Aug 17, 2007 at 02:05:57AM +0200, Nicholas Wieland wrote:



I was reading tuning(7), and I found that I should size my swap
double the size of my physical memory.
AFAIK that was true some years ago, when memory was not as cheap as
now, and following that guideline I should set my swap to 2GB, which
seems far too much for swap (at least to me ...). I will never need
this much memory as 1GB RAM and 2GB swap.
Is it still correct ? How can I resize with bsdlabel if I already
used all my disk space during install ?



Remember, disk sizes have shot up too.
No, 2 GB is not excessive.   You can get by with less, but you're
not likely to be using proportionately as much disk now as you used
to by going with 2X - I aim for a little over 2X.

Remember that swap gets used for crash dumps and also for paging.
Now, you may think that you want to keep your machine from paging
and in one sense that is true.   If you are so memory bound that
it has to page just to run, you're going to be so slow that it
seems to have froze (by today's standards).   But, the system does
write stuff to page space and for processes that are often called
it can speed things up.

So, it is not really a waste to assign that much to swap.

jerry



TIA,
  ngw

--
Nicholas Wieland
[EMAIL PROTECTED]



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
[EMAIL PROTECTED]


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
[EMAIL PROTECTED]


My understanding was that you should estimate swap size based on the
sizes of the programs which might be paged out. However, when I first set
up my system, I didn't know this and created 1G swap slices (one on each
disk) but I am not convinced that this was the best thing to do, since my
system almost never uses a noticible percentage of the swap space. right
now, I've got

[EMAIL PROTECTED] fusefs-sshfs]$ swapinfo
Device  1K-blocks UsedAvail Capacity
/dev/ad0s1b.eli   1048576 1148  1047428 0%
/dev/ad1s1b.eli   1048576 1096  1047480 0%
Total 2097152 2244  2094908 0%

And the system is under normal load. This system has 1G of RAM. Is there
any sense in having this much swap space when it's not being used?


Yes.  As was stated earlier, you will need that much space to save a core 
file if the system crashes.  If you don't care about troubleshooting major 
system crashes, then don't worry about it.  OTOH, disk sizes have grown so 
large that 2GB of swap is negligible use of space.  I always configure swap 
to be 2xRAM plus 200MB.  On a 300GB drive, that's less than 1% of the space 
available.


--
Paul Schmehl ([EMAIL PROTECTED])
Senior Information Security Analyst
The University of Texas at Dallas
http://www.utdallas.edu/ir/security/


Re: Swap size

2007-08-17 Thread Jerry McAllister
On Fri, Aug 17, 2007 at 02:05:57AM +0200, Nicholas Wieland wrote:

 I was reading tuning(7), and I found that I should size my swap  
 double the size of my physical memory.
 AFAIK that was true some years ago, when memory was not as cheap as  
 now, and following that guideline I should set my swap to 2GB, which  
 seems far too much for swap (at least to me ...). I will never need  
 this much memory as 1GB RAM and 2GB swap.
 Is it still correct ? How can I resize with bsdlabel if I already  
 used all my disk space during install ?

Remember, disk sizes have shot up too.
No, 2 GB is not excessive.   You can get by with less, but you're
not likely to be using proportionately as much disk now as you used
to by going with 2X - I aim for a little over 2X.

Remember that swap gets used for crash dumps and also for paging.
Now, you may think that you want to keep your machine from paging 
and in one sense that is true.   If you are so memory bound that
it has to page just to run, you're going to be so slow that it 
seems to have froze (by today's standards).   But, the system does
write stuff to page space and for processes that are often called
it can speed things up.  

So, it is not really a waste to assign that much to swap.

jerry

 
 TIA,
   ngw
 
 -- 
 Nicholas Wieland
 [EMAIL PROTECTED]
 
 
 
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to [EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-08-17 Thread Robert Huff

Andy Greenwood writes:

  And the system is under normal load. This system has 1G of
  RAM. Is there any sense in having this much swap space when it's
  not being used?

1) It is - usually - better to have it and not need it, than
need it and not have it.
2) While some machines have a very predictable working set of
programs, others vary very widely.  Trying to compute the right
value is an exercise in futility.
By default, I use the 2x current or expected memory rule
split over as many physical disks as possible.


Robert Huff
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-08-17 Thread Kris Kennaway
On Fri, Aug 17, 2007 at 11:07:14AM -0400, Andy Greenwood wrote:

 My understanding was that you should estimate swap size based on the 
 sizes of the programs which might be paged out. However, when I first 
 set up my system, I didn't know this and created 1G swap slices (one on 
 each disk) but I am not convinced that this was the best thing to do, 
 since my system almost never uses a noticible percentage of the swap 
 space. right now, I've got
 
 [EMAIL PROTECTED] fusefs-sshfs]$ swapinfo
 Device  1K-blocks UsedAvail Capacity
 /dev/ad0s1b.eli   1048576 1148  1047428 0%
 /dev/ad1s1b.eli   1048576 1096  1047480 0%
 Total 2097152 2244  2094908 0%
 
 And the system is under normal load. This system has 1G of RAM. Is there 
 any sense in having this much swap space when it's not being used?

swap is there to guard against overload conditions, not for normal
load.

If you are paging during normal operations your system performance
will be terrible, so you want to make sure you have enough RAM that
this does not happen.  However, when a transient load spike comes in,
would you prefer your system to slow down but keep working, or to kill
off all your processes?  Think of it as memory space insurance.

Kris


pgpvcvTfETSpH.pgp
Description: PGP signature


Re: Swap size

2007-08-16 Thread Kris Kennaway
On Fri, Aug 17, 2007 at 02:05:57AM +0200, Nicholas Wieland wrote:
 I was reading tuning(7), and I found that I should size my swap  
 double the size of my physical memory.
 AFAIK that was true some years ago, when memory was not as cheap as  
 now, and following that guideline I should set my swap to 2GB, which  
 seems far too much for swap (at least to me ...). I will never need  
 this much memory as 1GB RAM and 2GB swap.
 Is it still correct ?

2GB is a reasonable amount of swap space, and unless you plan to turn
your system on and leave it in the closet doing nothing, it will use
more memory than you think.

 How can I resize with bsdlabel if I already  
 used all my disk space during install ?

With a bit of work you can grow partitions (see growfs), but you
cannot shrink them.

Kris


pgpxxpQnKJcpS.pgp
Description: PGP signature


Re: Swap size

2007-08-16 Thread Eric Crist


On Aug 16, 2007, at 7:05 PMAug 16, 2007, Nicholas Wieland wrote:

I was reading tuning(7), and I found that I should size my swap  
double the size of my physical memory.
AFAIK that was true some years ago, when memory was not as cheap as  
now, and following that guideline I should set my swap to 2GB,  
which seems far too much for swap (at least to me ...). I will  
never need this much memory as 1GB RAM and 2GB swap.
Is it still correct ? How can I resize with bsdlabel if I already  
used all my disk space during install ?


TIA,
  ngw



From what I understand, the reasoning behind the math is that, if  
you have a kernel dump, there's enough room in swap to put the entire  
core into swap (so it's there when you've rebooted), and that there's  
enough room left in swap to allow the system to reboot, so you can  
debug.


If you're not worried about your .core files, then I wouldn't worry  
about the math of 2xmemory.


HTH
-
Eric F Crist
Secure Computing Networks


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-07-19 Thread Derek Ragona

At 03:03 AM 7/19/2007, Gabriel Linder wrote:

Hi,

I plan to setup FreeBSD 6.2-RELEASE on my Core Duo laptop with 1GB of RAM.

The handbook says ideal swap size is 2xRAM, so should I use 2GB of swap ?


Yes unless you know how many applications will ever be run and their run 
size.  The 2xRAM is so you can always have a reasonable performance 
allowing swap.  You can still run out of swap, and this will cause a 
panic.  With disks so cheap, why not use 2XRAM?



 This seems a bit huge to me, I never used more than 400MB on Linux.
If so, is there a limit of swap partition size (or number) on i386 (for 
Linux it's 2GB per partition and 32 partitions max, but I don't know for 
FreeBSD) ?


You can add more swap using a swap file you can check that out doing:
man swapon

I don't believe there is a limit to swap partitions, other than the limit 
on other partitions.


I have no knowledge on efficiency of a swap partition vs a swap file.

-Derek 
--

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-07-19 Thread [LoN]Kamikaze
Derek Ragona wrote:
 At 03:03 AM 7/19/2007, Gabriel Linder wrote:
 Hi,

 I plan to setup FreeBSD 6.2-RELEASE on my Core Duo laptop with 1GB of
 RAM.

 The handbook says ideal swap size is 2xRAM, so should I use 2GB of
 swap ?
 
 Yes unless you know how many applications will ever be run and their run
 size.  The 2xRAM is so you can always have a reasonable performance
 allowing swap.  You can still run out of swap, and this will cause a
 panic.  With disks so cheap, why not use 2XRAM?

Running out of swap doesn't cause a panic, it causes the largest process to be
killed.


  This seems a bit huge to me, I never used more than 400MB on Linux.
 If so, is there a limit of swap partition size (or number) on i386
 (for Linux it's 2GB per partition and 32 partitions max, but I don't
 know for FreeBSD) ?

For a Desktop System 400M should be enough, I don't remember my Desktop system
to ever use more than 1m of swap. However, the swap size should be large enough
for a dump during a panic. So if you want to be able to do some debugging if
you ever run into panics, your swap should be at least as large as your memory.
Assuming that you might add more memory one day something between 2 or 4GB of
swap look reasonable to me.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2007-07-19 Thread Gabriel Linder

[LoN]Kamikaze wrote:

Derek Ragona wrote:

At 03:03 AM 7/19/2007, Gabriel Linder wrote:

Hi,

I plan to setup FreeBSD 6.2-RELEASE on my Core Duo laptop with 1GB of
RAM.

The handbook says ideal swap size is 2xRAM, so should I use 2GB of
swap ?

Yes unless you know how many applications will ever be run and their run
size.  The 2xRAM is so you can always have a reasonable performance
allowing swap.  You can still run out of swap, and this will cause a
panic.  With disks so cheap, why not use 2XRAM?


Running out of swap doesn't cause a panic, it causes the largest process to be
killed.



 This seems a bit huge to me, I never used more than 400MB on Linux.
If so, is there a limit of swap partition size (or number) on i386
(for Linux it's 2GB per partition and 32 partitions max, but I don't
know for FreeBSD) ?


For a Desktop System 400M should be enough, I don't remember my Desktop system
to ever use more than 1m of swap. However, the swap size should be large enough
for a dump during a panic. So if you want to be able to do some debugging if
you ever run into panics, your swap should be at least as large as your memory.
Assuming that you might add more memory one day something between 2 or 4GB of
swap look reasonable to me.




Thanks for the precisions, I will go for 2xRAM so.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap Size Importance?

2006-09-29 Thread John Nielsen
On Friday 29 September 2006 11:52, Chris wrote:
 As a standard practice, I've always configured swap file to be double
 the size of real ram split across system and data disk. For example,
 8gb on da0 and 8gb on da1 if the system has 8g real ram. In practice,
 In 7 or 8 years, I've never seen swap used for anything but a few k
 of inactive processes and I would imagine if real active process
 swapping occurred, it would be an immediate indicator that the system
 that isn't responsive enough for use anymore and requires upgrade or
 tuning. Can't run a website process off disk and keep anyone coming
 to the site ;-). (BTW, I'm talking only about high end servers, not
 test boxes where I've seen lots of swapping).

 I'm at the point of attempting my first gvinum software raid-5 and
 realized, I need the entire disk storage of all three non-system
 drives to avoid pulling an 8gb chunk out of the drive sizes. The
 configuration is one scsi 72g system disk and 3 that will be used for
 the raid volume. I should mention I turn off dumps, haven't found the
 use for that in a production server since it should not be rebooting
 or it's back in the shop and another box is taking it's place.

 Is there any shortfall in performance or reliability to running
 production with swap equal in size to the 8gb of system memory? I
 can't think of any but don't want to make a hard to correct mistake
 once this thing goes in.

Nope. I routinely run boxes with 512MB or 1GB of swap, even if the RAM size is 
much higher than that. You won't have anywhere to save a crashdump in that 
case, but you seem to already be aware of that.

JN
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap Size Importance?

2006-09-29 Thread Jerry McAllister
On Fri, Sep 29, 2006 at 08:52:58AM -0700, Chris wrote:

 As a standard practice, I've always configured swap file to be double  
 the size of real ram split across system and data disk. For example,  
 8gb on da0 and 8gb on da1 if the system has 8g real ram. In practice,  
 In 7 or 8 years, I've never seen swap used for anything but a few k  
 of inactive processes and I would imagine if real active process  
 swapping occurred, it would be an immediate indicator that the system  
 that isn't responsive enough for use anymore and requires upgrade or  
 tuning. Can't run a website process off disk and keep anyone coming  
 to the site ;-). (BTW, I'm talking only about high end servers, not  
 test boxes where I've seen lots of swapping).
 
 I'm at the point of attempting my first gvinum software raid-5 and  
 realized, I need the entire disk storage of all three non-system  
 drives to avoid pulling an 8gb chunk out of the drive sizes. The  
 configuration is one scsi 72g system disk and 3 that will be used for  
 the raid volume. I should mention I turn off dumps, haven't found the  
 use for that in a production server since it should not be rebooting  
 or it's back in the shop and another box is taking it's place.
 
 Is there any shortfall in performance or reliability to running  
 production with swap equal in size to the 8gb of system memory? I  
 can't think of any but don't want to make a hard to correct mistake  
 once this thing goes in. 

It really depends on the number and size of processes you will be
running.  It you have a large memory and generally run a mix of
processes that will totally fit in memory, then it probably doesn't
doesn't matter much.   But, if you run enough to actually cause 
paging - which goes to swap space - then it becomes an issue.  Also,

I think some things that get pulled to execute often can get left
in swap space and accessed more quickly that all the way from main
disk each time.  eg the system keeps track of what it has in swap and 
it is more efficient to read from swap - less overhead.   But someone 
else should know more about that than I.

jerry

 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to [EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap Size Importance?

2006-09-29 Thread Chris


On Sep 29, 2006, at 9:06 AM, Jerry McAllister wrote:


On Fri, Sep 29, 2006 at 08:52:58AM -0700, Chris wrote:



Is there any shortfall in performance or reliability to running
production with swap equal in size to the 8gb of system memory? I


doesn't matter much.   But, if you run enough to actually cause
paging - which goes to swap space - then it becomes an issue.  Also,

I am assuming that real paging of active processes is death to that  
server anyway and means something else has to be throttled back with  
tuning of network bufs, apache or mysql. Same for crash dumps, can't  
run a server that is taking dumps or you lose your traffic.



I think some things that get pulled to execute often can get left
in swap space and accessed more quickly that all the way from main
disk each time.  eg the system keeps track of what it has in swap and
it is more efficient to read from swap - less overhead.   But someone


This is the part that concerned me. If one views a top on well  
running system and sees no swapping, I wanted to make certain there  
is no magic going on behind the scenes where processes have been  
mapped to swap in such a way that I could be currently benefitting  
from swap being higher than actual and not know it. If top is an  
accurate read on whether the system has placed high use processes in  
swap then it would suggest the first post is correct, and a memory  
rich system, where you configure to never exceed real memory, wastes  
that storage taken in swap. For expensive drives, given the sizes we  
use in RAM now, it's hard to justify. In the case of attempting this  
raid-5 configuration, it equates to the loss of 24G in scsi storage.  
I will run with 8g on the system drive.


Thank you very much for the responses.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2004-07-06 Thread Jerry McAllister
 
 Hello all,
 
 What swap size should i use having 768 Mb of memory?
 I've heard something about preformance degradation if
 swap size is bellow 2x of ram...

Traditionally, 2 1/2 X RAM size.  But everyone seems to have their
own prejudice on this.

It depends on the size and number of processes you will run
compared to the amount of RAM you have - paging goes to swap
space - as well as if you need to take a crash dump - crash
dumps need some more than RAM to do completely, etc.

jerry

 
 Thanks,
   Alexander.
 ___
 [EMAIL PROTECTED] mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to [EMAIL PROTECTED]
 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2004-07-05 Thread Bill Moran
Lists [EMAIL PROTECTED] wrote:
 Hello all,
 
 What swap size should i use having 768 Mb of memory?
 I've heard something about preformance degradation if
 swap size is bellow 2x of ram...

Other's have pointed out that you don't _need_ swap space.  If you have
enough RAM, you can operate without it.

However, if you need to do kernel core dumps (in the even you run into kernel
panic problems) you will need at least as much swap space as you have RAM,
plus a little.

Additionally, if your machine ever does start to swap, FreeBSD's VM code
_is_ optimized on the assumption that you have 2x your RAM in swap.  If
the machine starts to swap, you will get the best performance under all
loads (including _heavy_ swapping) if you have 2x RAM in swap.

However, FreeBSD still performs nicely with less swap than that.

-- 
Bill Moran
Potential Technologies
http://www.potentialtech.com
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2004-07-04 Thread Joshua Moore
I think for most cases if you have more then 512 MB of ram you can just 
have the swap size the same size as the amount of ram you have installed.
Lists wrote:

Hello all,
   What swap size should i use having 768 Mb of memory?
   I've heard something about preformance degradation if
   swap size is bellow 2x of ram...
   Thanks,
 Alexander.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]
 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Swap size

2004-07-04 Thread Lowell Gilbert
Lists [EMAIL PROTECTED] writes:

 What swap size should i use having 768 Mb of memory?
 I've heard something about preformance degradation if
 swap size is bellow 2x of ram...

You don't *need* ANY swap.  Until you fill up your RAM, at which point
it's nice to have some swap space instead of having the kernel start
killing processes.  

In order to do a crash dump, you need an overwritable partition that's
at least slightly larger than your RAM.  The swap partition is often
given this job as well as serving as swap space.

If you have some idea of your worst-case virtual memory usage,
allocate that much swap (less about the amount of RAM you have).  If
you don't know, either set aside a huge amount of space or experiment
and see how much you need (and then allocate half again as much to be
safe).  
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: swap size and zombie

2004-06-12 Thread Dan Nelson
In the last episode (Jun 12), Chris said:
 Looking at a web/email server with the following from top ...
 
 last pid: 29494;  load averages:  0.00,  0.00,  0.00   up 85+12:33:05  23:07:44
 39 processes:  1 running, 37 sleeping, 1 zombie
 CPU states:  0.0% user,  0.0% nice,  0.0% system,  0.0% interrupt,  100% idle
 Mem: 197M Active, 545M Inact, 176M Wired, 51M Cache, 112M Buf, 33M Free
 Swap: 2048M Total, 184K Used, 2048M Free
 
 Does it look like the swap file is way too big? The box has been
 online for awhile, yet it seems like the swap file is not utilized
 very much at all. For that matter, the server is clearly overpowered
 for what it does, but better than underpowered I suppose.

Sysinstall defaults to creating a swap partition that is 2x RAM, but
for large-memory systems it's usually overkill (do you really plan on
running 3gb worth of processes in a 1gb system?).  1x RAM is the
minimum if you want to be able to save kernel crashdumps though, so it
may be useful if you ever double the RAM in the box.
 
 Also, I cannot seem to get rid of that zombie... it happens at boot time:
 
 root   0  0.0  0.0 00  ??  ZW   - 0:00.00  (perl)

Run ps axl, find the parent process (PPID column), and fix the bug in it :)

-- 
Dan Nelson
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: swap size and a zombie

2004-06-11 Thread Kris Kennaway
On Fri, Jun 11, 2004 at 11:10:50PM -0500, Chris wrote:
 *This message was transferred with a trial version of CommuniGate(tm) Pro*
 
 
 Looking at a web/email server with the following from top ...
 
 
 last pid: 29494;  load averages:  0.00,  0.00,  0.00   up 85+12:33:05  23:07:44
 39 processes:  1 running, 37 sleeping, 1 zombie
 CPU states:  0.0% user,  0.0% nice,  0.0% system,  0.0% interrupt,  100% idle
 Mem: 197M Active, 545M Inact, 176M Wired, 51M Cache, 112M Buf, 33M Free
 Swap: 2048M Total, 184K Used, 2048M Free
 
 

 Does it look like the swap file is way too big? The box has been
 online for awhile, yet it seems like the swap file is not utilized
 very much at all. For that matter, the server is clearly overpowered
 for what it does, but better than underpowered I suppose.

It's only too much until you actually need to use it ;-)

For example, if you have 2GB of memory then you need a 2GB swap file
in order to take a kernel crash dump, if you ever run into a kernel
bug.  You only have ~1GB of RAM in that machine at the moment, so you
might be tempted to conclude that you have 1GB too much swap, but what
if you decide to add another 1GB of RAM in 6 months time?  You'd have
to reinstall that disk to make room.

Kris

P.S. Please wrap your lines at 70 characters so your emails may be
easily read.


pgptIkwYb4ixO.pgp
Description: PGP signature