Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 16 Jul 2009 21:41:43 +0400
From:      Anonymous <swell.k@gmail.com>
To:        freebsd-current@freebsd.org
Cc:        Rick Macklem <rmacklem@FreeBSD.org>
Subject:   [newnfs/client] -alldirs: listing files consumes too much memory
Message-ID:  <861vogcyp4.fsf@gmail.com>

next in thread | raw e-mail | index | archive | help
Let's create 335 empty files in /blah and try to list them over nfsv3.

# uname -vm
FreeBSD 8.0-BETA1 #0: Sat Jul  4 03:55:14 UTC 2009     root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386

# mkdir /blah
# (while [ $((i+=1)) -le 334 ]; do : >/blah/foo_$i; done)
# echo / -alldirs >/etc/exports
# /etc/rc.d/nfsd onestart
# mount -t newnfs -o nfsv3 0:/blah /mnt

# time -l ls /mnt >&-
        0.07 real         0.01 user         0.05 sys
      1672  maximum resident set size
        60  average shared memory size
       718  average unshared data size
       320  average unshared stack size
       247  page reclaims
         0  page faults
         0  swaps
         0  block input operations
         0  block output operations
         4  messages sent
         0  messages received
         0  signals received
         3  voluntary context switches
         8  involuntary context switches

# : >/blah/foo_335

# time -l ls /mnt >&-
[wait a few sec and type ^C]
^Ctime: command terminated abnormally
        4.22 real         2.21 user         1.80 sys
     70716  maximum resident set size
        52  average shared memory size
      1530  average unshared data size
       278  average unshared stack size
     17557  page reclaims
         0  page faults
         0  swaps
         0  block input operations
         0  block output operations
         6  messages sent
         0  messages received
         0  signals received
         3  voluntary context switches
       188  involuntary context switches

This was from qemu. On my main box with r195709M it doesn't stop after
eating over 2Gb memory when trying to list 886 entries in distfiles dir.

Is this one known?



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