Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 2 Dec 2003 00:34:26 +0100
From:      Erik Trulsson <ertr1013@student.uu.se>
To:        DG <david@fielden.com.au>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: size of rpc.statd process
Message-ID:  <20031201233426.GA97392@falcon.midgard.homeip.net>
In-Reply-To: <006301c3b850$aeb8ffc0$5401a8c0@borg.fielden.com.au>
References:  <20031201204611.GN15894@npkfbsd> <006301c3b850$aeb8ffc0$5401a8c0@borg.fielden.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Dec 02, 2003 at 08:18:35AM +1100, DG wrote:
> Greetings,
> 
> I have a 5.1-RELEASE installation running as a NFS server for a Linux client
> and another FreeBSD client.  I haven't done anything unusual that I am aware
> of when setupping the share, however looking at the output from top shows
> the following for rpc.statd:
> 
>   PID USERNAME PRI NICE   SIZE    RES STATE    TIME   WCPU    CPU COMMAND
>   359 root      96    0   257M    80K select   0:01  0.00%  0.00% rpc.statd
> 
> The SIZE is 257M (this is on a maching with 128M RAM and 1G swap) - that
> seems rather high.  The handbook says that it could occupy a lot of memory
> with a lot of clients, but for only 2 clients?
> 
> Is this of concern and, if so, how would I correct it?

This is answered in the FAQ:

 10.25. Why is rpc.statd using 256 megabytes of memory?

  No, there is no memory leak, and it is not using 256 Mbytes of
  memory. It simply likes to (i.e., always does) map an obscene amount
  of memory into its address space for convenience. There is nothing
  terribly wrong with this from a technical standpoint; it just throws
  off things like top(1) and ps(1).

  rpc.statd(8) maps its status file (resident on /var) into its address
  space; to save worrying about remapping it later when it needs to
  grow, it maps it with a generous size. This is very evident from the
  source code, where one can see that the length argument to mmap(2) is
  0x10000000, or one sixteenth of the address space on an IA32, or
  exactly 256MB.


-- 
<Insert your favourite quote here.>
Erik Trulsson
ertr1013@student.uu.se



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031201233426.GA97392>