Swapsize = RAM required?

Swapsize = RAM required?

Post by Mark Schleg » Thu, 01 Jan 1998 04:00:00



The manual that comes with Redhat 5.0 says that the swap
partition should be = amount of physical ram or 16M (which ever
is larger).  Is this an absolute requirement?  I ask because
I have 64Meg of ram but only partitions of 1) 353Meg and 2) 23Meg
for system and swap, and I don't want to repartition although
I could do that if needed.  The partition 3) already has
an established OS that I don't want to disturb (OS/2 4.0)
I seem to remember swap=ram is a rule of thumb that can be
broken if you have a lightly used machine, lots of ram or
a combo of this situation.

thanks,
Mark

 
 
 

Swapsize = RAM required?

Post by Mikael Bengtss » Thu, 01 Jan 1998 04:00:00


I remember that problem too, and I quote the RedHat 4.2 User's guide:
"If your computer has 16 MB of memory or less, you must create a swap
partition; even if you have more memory, a swap partition is
recomended. The size of your swap partition should be at least 16 MB
or the same as the amount of memory in your computer, whichever is
larger."
It sure seems like one ought to have a swap partition the size of
one's RAM, but I don't think that's necessary... Why should you need a
larger swap part. when you have more RAM. The swap part. is a
complement to the RAM, isn't it, like if some process needs more
memory it can use swap space on the HDD... I also have 64 MB RAM, but
still my swap part. is only 16 MB... So I would advice you to use only
16 MB of disk space for a swap part., especially since you don't have
infinite disk space...

Good luck!
/Micke



Quote:>The manual that comes with Redhat 5.0 says that the swap
>partition should be = amount of physical ram or 16M (which ever
>is larger).  Is this an absolute requirement?  I ask because
>I have 64Meg of ram but only partitions of 1) 353Meg and 2) 23Meg
>for system and swap, and I don't want to repartition although
>I could do that if needed.  The partition 3) already has
>an established OS that I don't want to disturb (OS/2 4.0)
>I seem to remember swap=ram is a rule of thumb that can be
>broken if you have a lightly used machine, lots of ram or
>a combo of this situation.

>thanks,
>Mark

+---------------------------+
| Mikael Bengtsson          |

| www.nada.kth.se/~d97-mbe  |
+---------------------------+

"Life's like a box of chocolates...
 you never know what you're gonna' get."
                          -Forrest Gump

 
 
 

Swapsize = RAM required?

Post by Kevin C. Weissm » Thu, 01 Jan 1998 04:00:00


: The manual that comes with Redhat 5.0 says that the swap
: partition should be = amount of physical ram or 16M (which ever
: is larger).  Is this an absolute requirement?  I ask because
: I have 64Meg of ram but only partitions of 1) 353Meg and 2) 23Meg
: for system and swap, and I don't want to repartition although
: I could do that if needed.  The partition 3) already has
: an established OS that I don't want to disturb (OS/2 4.0)
: I seem to remember swap=ram is a rule of thumb that can be
: broken if you have a lightly used machine, lots of ram or
: a combo of this situation.

You can use any amount of SWAP you want. Unless you're doing some really
huge apps, 23MB of swap and 64MB of RAM is probably more than enough.

: thanks,
: Mark
--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
Kevin C. Weissman (KW)            |ACORN "techie" and proud UNIX advocate.

                                  |Natural Selection; It's only natural

 
 
 

Swapsize = RAM required?

Post by Jürgen Exne » Thu, 01 Jan 1998 04:00:00


Actually there is exactly one rule with swap:
    The total of RAM + swap must be larger than the total amount of memory
required by the applications, which you want to run at the same time.

That said, there are two recommendations:
- If your swap is more than twice the size of your RAM, you might consider
to upgrade your RAM, because the increasing frequency of swapping will
degrade your overall system performance. Please note, this is only a rule of
thumb and depends on your needs and applications.
- Even with tons of RAM it's a good idea to have at least 4-8 MB of swap.
This will allow to swap unused or very seldom used process to disk (like
gettys for VTs, etc), thus allowing to use the RAM for more useful purposes,
e.g. disk caching.

jue

--
Jrgen Exner; jurgenex AT microsoft.com
Sorry for this anti-spam inconvenience


>I remember that problem too, and I quote the RedHat 4.2 User's guide:
>"If your computer has 16 MB of memory or less, you must create a swap
>partition; even if you have more memory, a swap partition is
>recomended. The size of your swap partition should be at least 16 MB
>or the same as the amount of memory in your computer, whichever is
>larger."
>It sure seems like one ought to have a swap partition the size of
>one's RAM, but I don't think that's necessary... Why should you need a
>larger swap part. when you have more RAM. The swap part. is a
>complement to the RAM, isn't it, like if some process needs more
>memory it can use swap space on the HDD... I also have 64 MB RAM, but
>still my swap part. is only 16 MB... So I would advice you to use only
>16 MB of disk space for a swap part., especially since you don't have
>infinite disk space...

>Good luck!
>/Micke



>>The manual that comes with Redhat 5.0 says that the swap
>>partition should be = amount of physical ram or 16M (which ever
>>is larger).  Is this an absolute requirement?  I ask because
>>I have 64Meg of ram but only partitions of 1) 353Meg and 2) 23Meg
>>for system and swap, and I don't want to repartition although
>>I could do that if needed.  The partition 3) already has
>>an established OS that I don't want to disturb (OS/2 4.0)
>>I seem to remember swap=ram is a rule of thumb that can be
>>broken if you have a lightly used machine, lots of ram or
>>a combo of this situation.

>>thanks,
>>Mark

>+---------------------------+
>| Mikael Bengtsson          |

>| www.nada.kth.se/~d97-mbe  |
>+---------------------------+

>"Life's like a box of chocolates...
> you never know what you're gonna' get."
>                          -Forrest Gump

 
 
 

Swapsize = RAM required?

Post by Alexander Bostro » Fri, 02 Jan 1998 04:00:00


Kevin C. Weissman skrev i meddelandet ...


>: The manual that comes with Redhat 5.0 says that the swap
>: partition should be = amount of physical ram or 16M (which ever
>: is larger).  Is this an absolute requirement?  I ask because
>You can use any amount of SWAP you want. Unless you're doing some really
>huge apps, 23MB of swap and 64MB of RAM is probably more than enough.

And also, you can use a file on the larger file system partition as a
swap sometimes if it becomes necessary.
 
 
 

Swapsize = RAM required?

Post by Ash » Fri, 02 Jan 1998 04:00:00


Quote:> >You can use any amount of SWAP you want. Unless you're doing some really
> >huge apps, 23MB of swap and 64MB of RAM is probably more than enough.

I've got 128mb ram, NO swap
Will this get me into trouble later? It works fine for now at least..
 
 
 

Swapsize = RAM required?

Post by Kevin C. Weissm » Fri, 02 Jan 1998 04:00:00


: > >You can use any amount of SWAP you want. Unless you're doing some really
: > >huge apps, 23MB of swap and 64MB of RAM is probably more than enough.

: I've got 128mb ram, NO swap
: Will this get me into trouble later? It works fine for now at least..

That should be fine. Although I've heard stories that Linux is slower if
there is no swap at all, even it isn't being used. Maybe you might want to
make a small (10MB) swap file, just to be sure.
--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
Kevin C. Weissman (KW)            |ACORN "techie" and proud UNIX advocate.

                                  |Natural Selection; It's only natural

 
 
 

Swapsize = RAM required?

Post by Roy Stogn » Fri, 02 Jan 1998 04:00:00



>> >You can use any amount of SWAP you want. Unless you're doing some really
>> >huge apps, 23MB of swap and 64MB of RAM is probably more than enough.

>I've got 128mb ram, NO swap
>Will this get me into trouble later? It works fine for now at least..

Are you running a seriously stressed web server or news server?  If not,
128 MB is more than enough...

A heavily used multiuser machine might need swap space beyond 128 MB, too;
I bet I could fill up physical RAM with a dozen instances of Netscape
Communicator alone.

You might get a slight speed boost from a swap partition, which would
allow Linux to swap out unused RAM for an even larger disk cache, but I
wouldn't bet on getting a noticable boost.

If your situation changes later, or if you are running heavy-RAM apps
(use "free" a few times, see how much RAM you actually have in use by
programs and how much is left over for disk cache), then you can alway
create a swap file later.
---
Roy Stogner

 
 
 

Swapsize = RAM required?

Post by TEX » Fri, 02 Jan 1998 04:00:00



> Actually there is exactly one rule with swap:
>     The total of RAM + swap must be larger than the total amount of memory
> required by the applications, which you want to run at the same time.

> That said, there are two recommendations:
> - If your swap is more than twice the size of your RAM, you might consider
> to upgrade your RAM, because the increasing frequency of swapping will
> degrade your overall system performance. Please note, this is only a rule of
> thumb and depends on your needs and applications.
> - Even with tons of RAM it's a good idea to have at least 4-8 MB of swap.
> This will allow to swap unused or very seldom used process to disk (like
> gettys for VTs, etc), thus allowing to use the RAM for more useful purposes,
> e.g. disk caching.

> jue

> --
> Jrgen Exner; jurgenex AT microsoft.com
> Sorry for this anti-spam inconvenience


> >I remember that problem too, and I quote the RedHat 4.2 User's guide:
> >"If your computer has 16 MB of memory or less, you must create a swap
> >partition; even if you have more memory, a swap partition is
> >recomended. The size of your swap partition should be at least 16 MB
> >or the same as the amount of memory in your computer, whichever is
> >larger."
> >It sure seems like one ought to have a swap partition the size of
> >one's RAM, but I don't think that's necessary... Why should you need a
> >larger swap part. when you have more RAM. The swap part. is a
> >complement to the RAM, isn't it, like if some process needs more
> >memory it can use swap space on the HDD... I also have 64 MB RAM, but
> >still my swap part. is only 16 MB... So I would advice you to use only
> >16 MB of disk space for a swap part., especially since you don't have
> >infinite disk space...

> >Good luck!
> >/Micke



> >>The manual that comes with Redhat 5.0 says that the swap
> >>partition should be = amount of physical ram or 16M (which ever
> >>is larger).  Is this an absolute requirement?  I ask because
> >>I have 64Meg of ram but only partitions of 1) 353Meg and 2) 23Meg
> >>for system and swap, and I don't want to repartition although
> >>I could do that if needed.  The partition 3) already has
> >>an established OS that I don't want to disturb (OS/2 4.0)
> >>I seem to remember swap=ram is a rule of thumb that can be
> >>broken if you have a lightly used machine, lots of ram or
> >>a combo of this situation.

> >>thanks,
> >>Mark

> >+---------------------------+
> >| Mikael Bengtsson          |

> >| www.nada.kth.se/~d97-mbe  |
> >+---------------------------+

> >"Life's like a box of chocolates...
> > you never know what you're gonna' get."
> >                          -Forrest Gump

But does it slow you down to have more swap??  I set up 100 megs with a
32 med ram.

Am I a bonehead???
--
Please remove "lnx" from address to e-mail me.

TEX

                Onward through the fog!

 
 
 

Swapsize = RAM required?

Post by James Youngma » Sat, 03 Jan 1998 04:00:00


  Mark> The manual that comes with Redhat 5.0 says that the swap
  Mark> partition should be = amount of physical ram or 16M (which
  Mark> ever is larger).  Is this an absolute requirement?

No.

  Mark> I ask because I have 64Meg of ram but only partitions of 1)
  Mark> 353Meg and 2) 23Meg for system and swap, and I don't want to
  Mark> repartition although I could do that if needed.  The partition
  Mark> 3) already has an established OS that I don't want to disturb
  Mark> (OS/2 4.0) I seem to remember swap=ram is a rule of thumb that
  Mark> can be broken if you have a lightly used machine, lots of ram
  Mark> or a combo of this situation.

Yep.

 
 
 

Swapsize = RAM required?

Post by Andrew Winkle » Sat, 03 Jan 1998 04:00:00


On most Unices, you need to have some page space, because the loading
of forked processes uses the page fault mechanism. I don't know if this
is true of Linux or not.

 
 
 

Swapsize = RAM required?

Post by Scott Savares » Sat, 24 Jan 1998 04:00:00


I am not sure the rule of thumb but I was told swap = double the RAM.
I in fact tripled my RAM, and it works fine. I use Java alot, and noticed
that the more swap I have the faster it runs (only slightly though)
Scott



>   Mark> The manual that comes with Redhat 5.0 says that the swap
>   Mark> partition should be = amount of physical ram or 16M (which
>   Mark> ever is larger).  Is this an absolute requirement?

> No.

>   Mark> I ask because I have 64Meg of ram but only partitions of 1)
>   Mark> 353Meg and 2) 23Meg for system and swap, and I don't want to
>   Mark> repartition although I could do that if needed.  The partition
>   Mark> 3) already has an established OS that I don't want to disturb
>   Mark> (OS/2 4.0) I seem to remember swap=ram is a rule of thumb that
>   Mark> can be broken if you have a lightly used machine, lots of ram
>   Mark> or a combo of this situation.

> Yep.

 
 
 

1. RAM required?

I have Redhat 6.0.

To run an Apache webserver with SSH, PPTP (Poptop?), and an ipchains
packet-filtering firewall how much RAM would be reasonable (32 meg, 64 meg
???).

To run an ipchains packet-filtering firewall with no services (just
packet-filtering and as a MASQ forwarding router) how much memory would be
required (16 meg? 32 meg???).

Thanks,
Micer

2. linux+ipmasq w/kali95

3. Increasing maximum swapsize

4. Mandrake Linux

5. A TX motherboard require Dimm ram to work?

6. TCP server question...

7. dosemu, does not require 16MB swap +ram to compile!

8. xv fatal error

9. HELP REQUIRED: Mach64 Video Card with 1Mb Ram

10. Why does Linux require ram to be equally cached?

11. RAM problems : help required

12. require() method not returning parent directory's require directive

13. http requires 5 Solaris U2s, https requires 50?!!