Samba Speed Question - Please Help!

Justen Marshall justen at
Tue Oct 10 08:24:38 GMT 2000


"Kevin (HxPro) Wheatley" <hxpro at> writes:

> > On Wed, 4 Oct 2000, Justen Marshall wrote:
> > 
> > [ lots of things about small files ]
> >
> I missed the start of the thread so please forgive me if you've
> already done this...
> what kind of performance do you get running running Unix commands on
> the Octane ??

Good question. I did the same tests you did, and I had about the same
results. Certainly, my results were within a whisker of yours, given
the minor differences in our hardware and network and so on.

This was on a dual Octane R10k 175MHz, the server.

  justen at lynx:lotsafiles 15 >timex ls > /dev/null
  real        0.23
  user        0.19
  sys         0.03
  justen at lynx:lotsafiles 16 >timex ls -l > /dev/null
  real        2.85
  user        1.52
  sys         1.29
  justen at lynx:lotsafiles 17 >ls -l | wc
           10001         90002        648907
  justen at lynx:lotsafiles 18 >timex du -ks .
  120456  .
  real        1.33
  user        0.05
  sys         1.24

  justen at lynx:lotsafiles 19 >timex find . -name file -print

  real        1.65
  user        0.07
  sys         1.34

And again, this timeq over NFS from an Indigo2 R10k 195MHz, network
100TX Ethernet.

  justen at uma:lotsafiles 6 >timex ls > /dev/null
  real        4.51
  user        0.20
  sys         0.07
  justen at uma:lotsafiles 7 >timex ls -l > /dev/null
  real       12.43
  user        1.54
  sys         3.42
  justen at uma:lotsafiles 8 >ls -l | wc
           10001         90002        648907
  justen at uma:lotsafiles 9 >timex du -ks .
  100452  .
  real        9.80
  user        0.09
  sys         3.30
  justen at uma:lotsafiles 10 >timex find . -name file -print
  real       10.55
  user        0.09
  sys         3.20

Those results aren't too far out from your own results. I'm perfectly
happy with the speed and cpu use of those tests, 

However, I used the CygWin time command to do the some of the same
experiments over Samba. I'm not 100% convinced that the CygWin utils
are as efficient as the Unix originals, but still...

  Z:\lotsafiles>c:\cygwin\bin\time ls > c:\temp\crap
  0.01user 0.03system 0:30.32elapsed 0%CPU (0avgtext+0avgdata 0maxresident)k
  0inputs+0outputs (0major+0minor)pagefaults 0swaps

  Z:\lotsafiles>c:\cygwin\bin\time ls > c:\temp\crap
  0.01user 0.00system 0:12.40elapsed 0%CPU (0avgtext+0avgdata 0maxresident)k
  0inputs+0outputs (0major+0minor)pagefaults 0swaps

(PS: Does anyone know how to do a redirect to some DOS/NT equivalent
of /dev/null? Is it even possible?)

Those PC/Samba results are only half the story. You can see that they
took a lot of elapsed time, but virtually no user OR system time.
Meaning, they were waiting around a long time for a reply from the
samba server. But CPU was being used somewhere... the smbd on the
server! It wavered between 10% and 50% CPU for the duration of that

My quest here is to reduce that CPU load to 5-15%. I need to be able
to serve a dozen or so operations with roughly that intensity of use,
and I don't like my chances of finding a spare 8cpu machine lying
around here :)

I will try the kernel config flags you suggested as soon as I get the
opportunity to reboot the machine a few times.

| Justen Marshall       |            | e-mail: justen at |
| Technical Director    |            | phone:   +61-2-9383-4831 |
| Animal Logic Pty Ltd  |            | fax:     +61-2-9383-4801 |
| Athiesm is a non-prophet organization.                        |

More information about the samba mailing list