From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751261AbcBFBTx (ORCPT ); Fri, 5 Feb 2016 20:19:53 -0500 Received: from szxga02-in.huawei.com ([119.145.14.65]:26810 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750780AbcBFBTv (ORCPT ); Fri, 5 Feb 2016 20:19:51 -0500 Message-ID: <56B54A2C.5010407@huawei.com> Date: Sat, 6 Feb 2016 09:19:40 +0800 From: Xishi Qiu User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:12.0) Gecko/20120428 Thunderbird/12.0.1 MIME-Version: 1.0 To: "Daniel K." CC: Linux MM , LKML Subject: Re: [RFC] why the amount of cache from "free -m" and /proc/meminfo are different? References: <56B45457.4010702@huawei.com> <56B48B2D.4020502@syse.no> In-Reply-To: <56B48B2D.4020502@syse.no> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.25.179] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020204.56B54A35.0010,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=0.0.0.0, so=2013-06-18 04:22:30, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 7d745241aad1755b5ced0c33398b01ce Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2016/2/5 19:44, Daniel K. wrote: > On 02/05/2016 07:50 AM, Xishi Qiu wrote: >> [root@localhost ~]# free -m >> total used free shared buff/cache available >> Mem: 48295 574 41658 8 6062 46344 >> Swap: 24191 0 24191 >> >> [root@localhost ~]# cat /proc/meminfo >> Buffers: 0 kB >> Cached: 3727824 kB >> Slab: 2480092 kB > > free and meminfo seems to match up pretty well to me. > > Are you really asking about display in MB vs kB? > Hi Daniel, No, I mean "Cached: 3727824 kB" and "buff/cache 6062M" are different. Does "buff/cache" include Buffers, Cached, and Slab? Thanks, Xishi Qiu > Drop the -m switch to free. > > Also, give 'man free' a spin, it explains what's behind the numbers. > > > Daniel K. > > . >