Linux in Memory view command free detailed

Source: Internet
Author: User

The free column of the add by zhj:-/+ Buffers/cache Row is the memory that is not actually used. The parameter-M in free-m refers to the output of data in megabytes

Original: http://liustb.blog.163.com/blog/static/1337080192011718112434416/

The Free command is used to view memory usage and is less expensive than the TOP command.

$free –m

Total used free shared buffers Cached

MEM:1002 769 232 0 62 421

-/+ Buffers/cache 286 715

Swap 1153 0 1153

Note: When you understand the output of the free command, you distinguish between two concepts: the first line (mem), which is for the operating system, and the buffer and cache for the operating system Is the memory that is used. The second line (-/+ Buffers/cache) is for the application, andfor the application,both the buffer and the cache belong to the memory that can be used.

So:

First Line ( mem):

Total: The amount of physical memory that the system can use is 1002;

Used indicates that the memory allocated is 769, including the buffer and cache memory 286 that have been actually used , theunused buffer Memory , unused cache Memory 421, i.e. 769 = + 421 + 286;

Free: Represents the allocated physical memory as 232;

Buffers: Buffer memory that has been allocated by the system but not used ;

Cached: The cache Memory 421 that has been allocated but not used;

second row ( -/+ buffers/cache);

Used: buffer and cache memory that have been really used by the application are 286;

Free: The memory that can be used by the application is 715, which includes: buffer memory that has been allocated but not used , cache memory allocated and unused 421 , has not been allocated memory 232, namely: 715 = + 421 + 232;

another: The difference between buffer and cache in Linux:

Buffer: The data memory to write to the hard disk;

Cache: Data memory read into memory;

Linux in Memory View command free detailed (GO)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.