LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-21-2009, 10:24 AM   #1
bye_nary
LQ Newbie
 
Registered: Dec 2009
Posts: 3

Rep: Reputation: 0
Memory %mem


Hi All.

I have access to a server running Linux Redhat. I need to run some very memory intensive processes.

My question is this:

What would happen to the server if I ran a process that used more and more memory until it got to 100% (shown in %mem when running 'ps au' command). Would it crash the server, or would it somehow know who to handle it (e.g. simply terminated the process)? I'd like to ask rather than try it out and crashing it.

Thanks.
 
Old 12-21-2009, 12:57 PM   #2
johnsfine
LQ Guru
 
Registered: Dec 2007
Distribution: Centos
Posts: 5,286

Rep: Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197
It would never get to 100% anyway.

You ought to have a decent amount of swap space.

If you have too little swap space, some process will get killed when too much mem+swap is used, but not necessarily the process using too much. The results might be as bad as crashing the whole server.

If you have enough swap space, a process trying to use "too much" memory will still get significantly less than 100% in %mem (which is ram and doesn't count swap). It and other processes will swap more, which depending on access pattern might drastically slow them down.

If you have enough swap space, setting the CPU priority low on the process that tries to use "too much" memory will tend to make it be the one that does more swapping and thus gets more of the impact of its own memory use. But that is an indirect effect. It is hard to make sure other processes won't slow to a crawl due to the excess swapping.

Last edited by johnsfine; 12-21-2009 at 01:01 PM.
 
  


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
accessing memory address outside standard mem einstern Linux - Software 3 11-23-2009 07:19 PM
c++ - how to find memory footprint of a GL display list (or mem usage on a GPU)? BrianK Programming 3 03-17-2008 01:14 PM
Difference between resident memory,shared memory and virtual memory in system monitor mathimca05 Linux - Newbie 1 11-11-2007 04:05 AM
is high mem support in a 2.6 kernel advised against for 1GB of memory? hedpe Linux - General 2 09-06-2005 09:35 AM
Help!?! RH 8 Memory Mapping -High Memory-Virtural Memory issues.. Merlin53 Linux - Hardware 2 06-18-2003 04:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:08 PM.

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