Linux-Doc Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] docs: proc.rst: meminfo: briefly describe gaps in memory accounting
@ 2021-04-20  8:51 Mike Rapoport
  2021-04-20  9:10 ` Michal Hocko
  0 siblings, 1 reply; 3+ messages in thread
From: Mike Rapoport @ 2021-04-20  8:51 UTC (permalink / raw)
  To: Jonathan Corbet
  Cc: Alexey Dobriyan, Andrew Morton, Michal Hocko, Mike Rapoport,
	Mike Rapoport, linux-doc, linux-fsdevel, linux-kernel, linux-mm

From: Mike Rapoport <rppt@linux.ibm.com>

Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>
---
 Documentation/filesystems/proc.rst | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst
index 48fbfc336ebf..bf245151645b 100644
--- a/Documentation/filesystems/proc.rst
+++ b/Documentation/filesystems/proc.rst
@@ -929,8 +929,15 @@ meminfo
 ~~~~~~~
 
 Provides information about distribution and utilization of memory.  This
-varies by architecture and compile options.  The following is from a
-16GB PIII, which has highmem enabled.  You may not have all of these fields.
+varies by architecture and compile options. Please note that is may happen
+that the memory accounted here does not add up to the overall memory usage
+and the difference for some workloads can be substantial. In many cases
+there are other means to find out additional memory using subsystem
+specific interfaces, for instance /proc/net/sockstat for networking
+buffers.
+
+The following is from a 16GB PIII, which has highmem enabled.
+You may not have all of these fields.
 
 ::
 
-- 
2.29.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] docs: proc.rst: meminfo: briefly describe gaps in memory accounting
  2021-04-20  8:51 [PATCH] docs: proc.rst: meminfo: briefly describe gaps in memory accounting Mike Rapoport
@ 2021-04-20  9:10 ` Michal Hocko
  2021-04-20 12:05   ` Mike Rapoport
  0 siblings, 1 reply; 3+ messages in thread
From: Michal Hocko @ 2021-04-20  9:10 UTC (permalink / raw)
  To: Mike Rapoport
  Cc: Jonathan Corbet, Alexey Dobriyan, Andrew Morton, Mike Rapoport,
	linux-doc, linux-fsdevel, linux-kernel, linux-mm

On Tue 20-04-21 11:51:05, Mike Rapoport wrote:
> From: Mike Rapoport <rppt@linux.ibm.com>

Some trivial changelog would be better than nothing.

> Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>

But I do agree that this is a useful information to have in the
documentation. Having networking counters as an example is helpful as
well. I am not familiar with those myself much and I do remember there
is much to it than just sockstat. It would be great to consult this with
some networking expert and extend the documentation for that case which
tends to be quite common AFAIK.

Anyway this is already an improvement and a step into the right
direction.

Acked-by: Michal Hocko <mhocko@suse.com>

one nit below
> ---
>  Documentation/filesystems/proc.rst | 11 +++++++++--
>  1 file changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst
> index 48fbfc336ebf..bf245151645b 100644
> --- a/Documentation/filesystems/proc.rst
> +++ b/Documentation/filesystems/proc.rst
> @@ -929,8 +929,15 @@ meminfo
>  ~~~~~~~
>  
>  Provides information about distribution and utilization of memory.  This
> -varies by architecture and compile options.  The following is from a
> -16GB PIII, which has highmem enabled.  You may not have all of these fields.
> +varies by architecture and compile options. Please note that is may happen

that it may happen

> +that the memory accounted here does not add up to the overall memory usage
> +and the difference for some workloads can be substantial. In many cases
> +there are other means to find out additional memory using subsystem
> +specific interfaces, for instance /proc/net/sockstat for networking
> +buffers.
> +
> +The following is from a 16GB PIII, which has highmem enabled.
> +You may not have all of these fields.
>  
>  ::
>  
> -- 
> 2.29.2

-- 
Michal Hocko
SUSE Labs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] docs: proc.rst: meminfo: briefly describe gaps in memory accounting
  2021-04-20  9:10 ` Michal Hocko
@ 2021-04-20 12:05   ` Mike Rapoport
  0 siblings, 0 replies; 3+ messages in thread
From: Mike Rapoport @ 2021-04-20 12:05 UTC (permalink / raw)
  To: Michal Hocko
  Cc: Jonathan Corbet, Alexey Dobriyan, Andrew Morton, Mike Rapoport,
	linux-doc, linux-fsdevel, linux-kernel, linux-mm

On Tue, Apr 20, 2021 at 11:10:03AM +0200, Michal Hocko wrote:
> On Tue 20-04-21 11:51:05, Mike Rapoport wrote:
> > From: Mike Rapoport <rppt@linux.ibm.com>
> 
> Some trivial changelog would be better than nothing.
 
oh, sure.

> > Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>
> 
> But I do agree that this is a useful information to have in the
> documentation. Having networking counters as an example is helpful as
> well. I am not familiar with those myself much and I do remember there
> is much to it than just sockstat. It would be great to consult this with
> some networking expert and extend the documentation for that case which
> tends to be quite common AFAIK.
 
I've found a citation from one of Eric Dumazet's emails [1], and used that
instead:

... subsystem specific interfaces, for instance /proc/net/sockstat for TCP
memory allocations

[1] https://lore.kernel.org/lkml/CANn89iKprp7WYeZy4RRO5jHykprnSCcVBc7Tk14Ui_MA9OK7Fg@mail.gmail.com

> Anyway this is already an improvement and a step into the right
> direction.
> 
> Acked-by: Michal Hocko <mhocko@suse.com>
> 
> one nit below
> > ---
> >  Documentation/filesystems/proc.rst | 11 +++++++++--
> >  1 file changed, 9 insertions(+), 2 deletions(-)
> > 
> > diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst
> > index 48fbfc336ebf..bf245151645b 100644
> > --- a/Documentation/filesystems/proc.rst
> > +++ b/Documentation/filesystems/proc.rst
> > @@ -929,8 +929,15 @@ meminfo
> >  ~~~~~~~
> >  
> >  Provides information about distribution and utilization of memory.  This
> > -varies by architecture and compile options.  The following is from a
> > -16GB PIII, which has highmem enabled.  You may not have all of these fields.
> > +varies by architecture and compile options. Please note that is may happen
> 
> that it may happen

Right.
 
> > +that the memory accounted here does not add up to the overall memory usage
> > +and the difference for some workloads can be substantial. In many cases
> > +there are other means to find out additional memory using subsystem
> > +specific interfaces, for instance /proc/net/sockstat for networking
> > +buffers.
> > +
> > +The following is from a 16GB PIII, which has highmem enabled.
> > +You may not have all of these fields.
> >  
> >  ::
> >  
> > -- 
> > 2.29.2
> 
> -- 
> Michal Hocko
> SUSE Labs

-- 
Sincerely yours,
Mike.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-20  8:51 [PATCH] docs: proc.rst: meminfo: briefly describe gaps in memory accounting Mike Rapoport
2021-04-20  9:10 ` Michal Hocko
2021-04-20 12:05   ` Mike Rapoport

Linux-Doc Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-doc/0 linux-doc/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-doc linux-doc/ https://lore.kernel.org/linux-doc \
		linux-doc@vger.kernel.org
	public-inbox-index linux-doc

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-doc


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git