Samba performance issues: stat calls
Steve Langasek
vorlon at netexpress.net
Fri Apr 4 19:22:18 GMT 2003
On Fri, Apr 04, 2003 at 10:19:57AM -0800, Richard Sharpe wrote:
> On Fri, 4 Apr 2003, Simo Sorce wrote:
> > On Fri, 2003-04-04 at 19:53, Richard Sharpe wrote:
> > > On Fri, 4 Apr 2003, Andrew Bartlett wrote:
> > >
> > > > On Thu, 2003-04-03 at 18:06, Michael B.Allen wrote:
> > > > > On Wed, 2 Apr 2003 19:26:36 -0800 (PST)
> > > > > Richard Sharpe <rsharpe at richardsharpe.com> wrote:
> > > > >
> > > > > > That looks like an average of more than one stat call per SMB. Not good!
> > > > >
> > > > > Don't you have to stat each label in a path as you walk it?
> > > >
> > > > Yes, given how Samba works, one stat per smb is actually pretty low...
> > >
> > > Well, stat just hit number 1 problem for me :-)
> > >
> > > I have got to look at converting it to an IOCTL in our case, because our
> > > file system keeps times a 64-bit quantities, but POSIX is so aweful that
> > > we have to convert them to 32-bits in our POSIX subsystem and then back to
> > > 64-bits in Samba.
> > even in 64bit systems??
> The standard POSIX stat call returns 32-bit times, I believe.
On my 64-bit Linux systems, I have:
struct stat
{
[...]
__time_t st_atime; /* Time of last access. */
__time_t st_mtime; /* Time of last modification. */
__time_t st_ctime; /* Time of last status change. */
[...]
}
AFAIK (and I don't have a copy of the spec handy to confirm -- just
manpage references), POSIX only defines that these members should be
'time_t', it does not define the size of time_t itself. I see __time_t
defined here as a 'long int', which makes it 64-bit on 64-bit
architectures.
So I don't think your hands are tied by POSIX zipties here, though of
course changing the size of a member of a published structure is
difficult in its own right.
--
Steve Langasek
postmodern programmer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20030404/f5a89ed4/attachment.bin
More information about the samba-technical
mailing list