[Samba] Troubleshooting poor (small) random read performance -- serverid.tdb?

Ray Van Dolson rvandolson at esri.com
Thu Jun 19 15:48:52 MDT 2014


On Thu, Jun 19, 2014 at 02:37:30PM -0700, Jeremy Allison wrote:
> On Thu, Jun 19, 2014 at 11:52:12AM -0700, Ray Van Dolson wrote:
> > 
> > Shoot, wish I'd done some Googling and stumbled across that prior to
> > bumping up to RHEL7!
> > 
> > With that said, here are a couple of updates:
> > 
> > All configs are using "default" options plus these:
> > 
> >     aio read size = 1
> >     aio write size = 1
> >     strict locking = no
> >     use sendfile = yes
> > 
> > - RHEL 7.0 with the stock Samba 4.1.1 - no significant improvement
> >   observed on the application side.  smbd processes still showed very
> >   high CPU utilization, system load went up to 10 but minimal disk
> >   activity seen.  strace on smbd processes looked significantly
> >   different from what I saw on 3.6.x.  My fu wasn't strong enough to
> >   discern where most time was being spent.
> > 
> > - RHEL 7.0 with Sama 4.1.8 stolen from Fedora 20 - definite improvement
> >   observed.  System load stayed around 1.0 or lower and on the
> >   application side we saw processing occurring at a pretty good clip,
> >   though not as good as Windows.  There are parent processing nodes and
> >   children processing nodes... some of the child nodes didn't get fully
> >   "spun up" and were complaining about being unable to access some of
> >   the data they needed.... which led us to....
> > 
> > - RHEL 7.0 with Samba 4.1.8 and "locking = no" set on the share from
> >   which data is being read.  Best results by far -- basically matched
> >   Windows performance.  All parent and "child" nodes had their CPU's
> >   fully maxed out indicating they were able to get at the data they
> >   needed quickly.
> 
> So are you using "locking = no", "strict locking = no"
> or "posix locking = no" ?
> 
> That's not entirely clear from your message, and would
> be an interesting data point to know !
> 
> Cheers,
> 
> 	Jeremy.
> 

We're using strict locking = no at the global level and locking = no at
the share level.  The latter option is where we get good performance
improvements for this workload.

I'm not explicitly setting posix locking at all.

I'll note that we also downgraded to RHEL7's Samba 4.1.1 and tried with
"locking = no" set at the share level.  It did not perform well and we
once again observed system load at 10.0+ and a general lack of
performance feeding data back to our processing nodes.

For now we'll stick with 4.1.8.  Here's the final config we're using:

[global]
    workgroup = WORKGROUP
    netbios aliases = ALIAS
    log file = /var/log/samba/log.%m
    max log size = 50
    security = user
    passdb backend = tdbsam
    load printers = no

    aio read size = 1
    aio write size = 1
    strict locking = no
    use sendfile = yes

[acf_inputs]
    path = /data/acf_inputs
    read only = yes
    browseable = yes
    locking = no

Ray


More information about the samba mailing list