当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 5 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : Memory, Swap Management
帖子发表于 : 2005-12-18 13:30 
头像

注册: 2005-10-16 23:26
帖子: 532
地址: 泉州
送出感谢: 0 次
接收感谢: 3
A lot of Linux newbies, myself included are often astonished at the amount (%) of memory used by Linux as opposed to, say, Windows on comparable systems. If you look at the System Monitor (Applications -> System Tools -> System Monitor), you can find the amount of memory used by your system. If you leave your computer on for a long period (say more than a day) then the memory usage seems to keep going up. This is a “good thing”. Let me explain why.

Linux actively uses free available memory to improve your system’s performance. Let’s say you have 1 GB of main memory (don’t we all wish!). Now, suppose all the programs you are running together require only 200 MB of memory. What happens to the other 800 MB of the available memory?

On a linux system, the memory is used to “cache” data that is used by the CPU. The idea behind caching is that it takes longer for your CPU to access data on the hard drive than it does to access data that is present in the main memory. So caching using the main memory effectively speeds up the system. On a windows system, there is no such optimization, so free memory is wasted as it does not get used.

Now when an application really needs all the memory that is used for caching, Linux pops out the cached data and makes the required memory available. As a last option, if all of the main memory is used up, then the memory you set aside in your swap partition is used too.

Try the command:
$free -m

to see what your memory usage is. The first line of results is fairly obvious. The second line tells you what the applications “see”, and should tell you how much memory is actually being used by the applications themselves.

Another used command is “top” which gives you a look at the memory/cpu usage and other details about the processes that are running on your computer - all at the terminal. I much prefer it to the GUI-based System Monitor myself.

Knowing that all the memory I paid for is being used to the max makes me feel all warm and fuzzy. For a moment earlier today, I thought there was something wrong, since almost all of my memory was being used, and I was hardly running anything intensive - now I am at ease - there was something wrong earlier, when the memory was not being used by Windows - now I know!!

文章来源于http://ubuntu.wordpress.com/tag/commands/


_________________
You make it fun
It will make you fun


页首
 用户资料  
 
2 楼 
 文章标题 :
帖子发表于 : 2005-12-18 15:31 

注册: 2005-11-18 13:37
帖子: 19
送出感谢: 0 次
接收感谢: 0 次
翻译?


页首
 用户资料  
 
3 楼 
 文章标题 :
帖子发表于 : 2005-12-20 13:41 
头像

注册: 2005-10-16 23:26
帖子: 532
地址: 泉州
送出感谢: 0 次
接收感谢: 3
总的意思就是说,在linux中内存如果所剩无几了,说明你用银子买的内存被充分利用了,而不是闲置,而在windows中就是浪费了,因为你买了东西没有用。
而且充分利用内存可以加速系统的速度,因为数据存在内存中肯定比存在硬盘上反应快


_________________
You make it fun
It will make you fun


页首
 用户资料  
 
4 楼 
 文章标题 :
帖子发表于 : 2005-12-21 14:21 

注册: 2005-12-20 21:26
帖子: 122
地址: UESTC
送出感谢: 0 次
接收感谢: 0 次
这个是linux的一个特点,对提升机器的性能有很大的好处,同时linux的内存管理模式也和windows有很大的不同,这个可能会给刚转到linux的朋友一点疑惑。


页首
 用户资料  
 
5 楼 
 文章标题 :
帖子发表于 : 2006-01-27 21:03 

注册: 2005-12-17 2:24
帖子: 19
送出感谢: 0 次
接收感谢: 0 次
我的英文很poor
我现在只能把SWAP认为是WIN下的虚拟缓存,其实好象不是这样理解的
LINUX有个好处就是在程序运行是掉用库的时候调用后,如果其他程序也用这个库就可以共享使用,好象WIN必须得再次调用。这也是LINUX一个好处吧


_________________
OS:UBUNTU Version6.10+WindowsXP sp1
CPU:Intel Celeron D 320 2.4G
MAINBOARD:ASUS P4P800S-X
RAM:V-DATA 256MDDR400*2
HD:Seagate 7200rpm 8M 80G+Maxtor 5400rpm 2M 20G
DISPLAY CARD:ATI Radeon9550


页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 5 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 4 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译