LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-03-2004, 03:02 PM   #1
podollb
Member
 
Registered: Oct 2003
Location: Grand Forks, ND
Distribution: Suse/Slackware/RH
Posts: 161

Rep: Reputation: 30
Swap size (Limit?)


Is there a limit to the size of swap (file or partition) I can have on my Linux machine? I know since it is a 32-bit architecture I can only have a file up to 4GB (so I know even if Linux allowed me to have a huge swap file 4GB is the limit if there is no other kernel limits) Anyone have any insight to this?
I search google and came across a bunch of posts regarding this and some said 2GB but all the posts were old and not from a trusted source.
 
Old 05-03-2004, 03:07 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
There is no limit.. but if your going to be using this as a desktop.. I never exceed 200 megs for swap.. there's really no reason to use more as it won't be used ever or rarely, if it does get used constantly, that just means your RAM isn't doing its job efficiently.
For servers, just all depends on what kind of load your going to have, but just like a desktop, if your server ever hits swap in most cases, means there is something wrong or you need more RAM.

PS. Old rule of thumb, create your swap double the size of the amount of RAM you have.. but if you have 256 or more.. I wouldn't exceed 256mb for it.. unless its a server, etc.
 
Old 05-03-2004, 03:08 PM   #3
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 475Reputation: 475Reputation: 475Reputation: 475Reputation: 475
A swap partition is only really useful if you have little memory (or an old box) or are doing a lot of memory intensive work.

If you have 256mb or more, you really don't need a large swap partition. Using the swap is normally a sign that your memory can't cope.

Why do you need such a large partition?
 
Old 05-03-2004, 03:18 PM   #4
podollb
Member
 
Registered: Oct 2003
Location: Grand Forks, ND
Distribution: Suse/Slackware/RH
Posts: 161

Original Poster
Rep: Reputation: 30
Unhappy

We have a cluster and each node has dual processors and and 1GB of RAM, that is no where near enough -- and the current swap is 2GB, but we are upgrading the RAM to 3GB or 4GB and need to increase the swap too... Since the datasets we use in our mpi application get to be huge and will max out the memory (and occasionally if numerous mpi applications are running need to do some swapping which is fine since it won't happen to terribly often). This application is used to running on a Cray X1 which can have 32768GB of RAM which I don't think Linux will allow so I was just curious if we could allocate 8GB of swap or if we have to create 4 seperate 2GB swap (partitions or files)...
 
Old 05-03-2004, 03:38 PM   #5
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
Quote:
Originally posted by podollb
We have a cluster and each node has dual processors and and 1GB of RAM, that is no where near enough -- and the current swap is 2GB, but we are upgrading the RAM to 3GB or 4GB and need to increase the swap too... Since the datasets we use in our mpi application get to be huge and will max out the memory (and occasionally if numerous mpi applications are running need to do some swapping which is fine since it won't happen to terribly often). This application is used to running on a Cray X1 which can have 32768GB of RAM which I don't think Linux will allow so I was just curious if we could allocate 8GB of swap or if we have to create 4 seperate 2GB swap (partitions or files)...
Like mentioned above as this info was not mentioned.. there is no limit to swap.. at least not with the later kernels.
 
Old 05-03-2004, 03:43 PM   #6
podollb
Member
 
Registered: Oct 2003
Location: Grand Forks, ND
Distribution: Suse/Slackware/RH
Posts: 161

Original Poster
Rep: Reputation: 30
Great thanks!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
2GB swap limit twantrd Linux - General 2 10-19-2004 08:56 PM
~/ size limit bm1 Slackware 5 09-23-2004 07:10 AM
Why should you give the size of the swap disk as twice the size of RAM vmniza Linux - Newbie 3 09-17-2004 02:13 AM
2.1 Gb size limit?? pk21 Linux - General 5 08-30-2003 02:40 PM
Size limit? pyropenguin Linux - Networking 1 12-18-2002 12:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration