On Saturday, 2 May 2020 00:08:24 BST Raphael MD wrote:
> On Fri, 1 May 2020 at 18:49 J. Roeleveld <jo...@antarean.org> wrote:
> > On 1 May 2020 21:50:02 CEST, Raphael MD <raph...@gmail.com> wrote:
> > >Hello!
> > >
> > >Could I turn my Linux swap off.
> > >I have 32 GB of RAM memory, I suppose my system don’t need swap,
> > >because
> > >I’vea lot of RAM, is this true?
> > >
> > >Thanks
> > 
> > This question keeps getting asked every time people go past some imaginary
> > large figure of RAM.
> > 
> > First time I encountered it was somewhere in the 1990s. A friend had a
> > machine with 64MB ram, a massive amount at that time, and disabled all
> > swap. He was surprised his machine crashed because of memory issues,
> > until I asked what he was running. The list included several memory
> > intensive applications.
> > He never asked that again and adds it to all his machines.
> > 
> > My desktop has 32GB and also has some swap. I do regularly see it used and
> > not because of memory leaks like Dale is mentioning, although those do
> > appear on occasion. On my desktop it's mostly because I have a lot of
> > stuff
> > running the whole time.
> > 
> > So, yes, you still need swap and always will. Unless you put about 10
> > times the current magical figure in a desktop. In my view, that would be
> > 320GB for now, and in another 5 years, that would be around 640GB.
> > When you have that level of overkill in a desktop, I will not consider OOM
> > to be likely.
> > 
> > 
> > --
> > Joost
> > 
> > --
> > Sent from my Android device with K-9 Mail. Please excuse my brevity.
> 
> Well, it’s figuring that some sort of swap space is necessary, but
> regarding pressure level on kernel, can I setup it to zero or I’m obligated
> to put some number because I’ve a swap file?
> 
> Thanks

Only you know how you're using your PC and if the 32G of RAM can/will be used 
up at some point.  I can assure you if you decide to compile chromium with 
some silly --jobs number, you *will* run out of memory and wish you had set 
some swap at the time.  I don't think I have ever regretted having swap in 
place and still revisit old systems I should have retired years ago to add 
some more swap to make sure a memory hungry application or compilation can run 
and complete without OOM errors.

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to