Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm just configuring some backend stuff and going through my aws.micro install.

Using htop I can see my memory is hovering around 530mb out of a total 590mb.

The colouring in htop still shows it being green so at first I wasn't worried, but is 60mb leeway enough to run my website?

Htop output

htop

free -m

free -m

share|improve this question

closed as off-topic by Ward, Katherine Villyard, mdpc, dawud, Tim Brigham Mar 17 at 16:15

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions must be relevant to professional system administration. Server Fault is dedicated to professional system and network administrators. End user and enthusiast questions are off-topic (contact your system administrator or hire a professional to help you out). Please see the Help Center for more information." – mdpc, dawud
If this question can be reworded to fit the rules in the help center, please edit the question.

1  
I don't know what is going on, on your server. You didn't provide enough details. The free -m output would have been a lot more useful. –  Zoredache Mar 11 at 23:35
1  
That shows 14MB free, not 75. That's a bit scary. What's the value of vm/min_free-kbytes? You have lots of free swap, so why are you concerned? Are you worried about running out of memory and refusing allocations? Are are you worried about thrashing due to swapping/paging? –  David Schwartz Mar 11 at 23:43
1  
Your swap usage is ~18%, your cache/buffers is a very low percentage of ram at ~10%, you have very little free space available. I think you should be looking at increasing the RAMs. –  Zoredache Mar 11 at 23:47
1  
@UzumakiDev You need free RAM because you may need memory in a context in which you can't easily discard cached pages. In contexts where you can discard, you don't need free memory at all. You can make the memory free right at the instant you need it, so no need to worry about that. –  David Schwartz Mar 11 at 23:48
1  
@UzumakiDev Neither of those things will help. Turning off services that use RAM will just make the system use that RAM for something else. Adding more RAM will just cause the system to enlarge the cache. If your system is not maintaining enough free RAM, you have to change the vm tuning so it keeps more RAM free. This kind of sucks because using less RAM makes the system slower (just like removing the RAM would) but you need it to be stable. –  David Schwartz Mar 11 at 23:53

1 Answer 1

up vote 2 down vote accepted

Generally, 60MB is enough leeway. You can check with cat /proc/sys/vm/min_free_kbytes. That will tell you the amount of free RAM the server thinks it needs, and it's typically around 64MB. A bit less than that is fine -- unless you have some strange I/O storm, the amount of free RAM needed is extremely small.

If you use NFS heavily or have some kind of strange RAID controller that might require lots of free physical RAM during interrupt handling, you can raise this value. If you're having no symptoms, it's almost certainly sufficient.

share|improve this answer
    
I haven't ran into any problems as of yet, but this website has only just gone live with hardly any traffic. I just don't want to be putting out fires within a week. I just checked free -m and it says I have buffers/cache free 59 and your command gave me 3mb, so I think im right to say I'm pretty safe? –  UzumakiDev Mar 11 at 23:46
    
Yeah. For some reason, your hardware/platform needs very little free memory. –  David Schwartz Mar 11 at 23:47

Not the answer you're looking for? Browse other questions tagged or ask your own question.