Bug 1380 - Samba on ext3 data=journal filesystem causes hangs/random errors
Samba on ext3 data=journal filesystem causes hangs/random errors
Status: RESOLVED INVALID
Product: Samba 3.0
Classification: Unclassified
Component: File Services
3.0.2
Other Linux
: P3 major
: none
Assigned To: Samba Bugzilla Account
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2004-05-25 03:37 UTC by Darryl Dixon
Modified: 2005-02-20 17:23 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Darryl Dixon 2004-05-25 03:37:05 UTC
When running samba on ext3 filesystems mounted with data=journal, samba fails
randomly when serving files and directory listings to clients.
Specifically:
Approximately every 30 seconds, when using any CIFS client (including both WinXP
in a Samba Domain and smbclient on the Samba server itself) the client will hang
(on WinXP explorer itself will hang indefinitely, with smbclient it will hang
for ~20 seconds then fail with a dskattr timeout error) and simultaneously in
the syslog the two events will be registered:
"""
May 20 22:43:22 fileserver-fc1 mount.smbfs[6515]: [2004/05/20 22:43:22, 0]
client/smbmount.c:do_connection(237)
May 20 22:43:22 fileserver-fc1 mount.smbfs[6515]:   6515: tree connect failed:
ERRDOS - ERRnosuchshare (You specified an invalid share name)
"""
This is replicable across reboots and various configuration changes in the smb.conf.

Making the single change in /etc/fstab to remove data=journal from the various
ext3 filesystems on the server (some of which hold directories defined as shares
in smb.conf) and rebooting removed the issue entirely.

The platform is a fully updated Fedora Core 1 server, running Samba 3.0.2 with
two harddrives mirrored with md and divided up with LVM.
Comment 1 Björn Jacke 2004-10-20 02:53:33 UTC
you are saying that you use XP or smbclient as clients but in the log there are
smbfs errors. Are you reexporting smb shares mounted via smbfs? Please add some
more details about your setup.
Comment 2 Darryl Dixon 2004-10-20 13:41:28 UTC
(In reply to comment #1)
> you are saying that you use XP or smbclient as clients but in the log there are
> smbfs errors. Are you reexporting smb shares mounted via smbfs? Please add some
> more details about your setup.


Sorry, thought it was clear, will try again:
I have a server running Fedora Core 1 with Samba 3.0.2.  Samba serves up files
that are stored on the server on an ext3 filesystem, which in turn sits on an
LVM volume that lives on some mirrored disk.  When the ext3 filesystem is
mounted with the 'data=journal' option Samba experiences serious errors that
cause large problems for any client system trying to use the Samba shares.

The symptoms of the errors that Samba generates are that every 30 seconds the
client system trying to access the files will hang, and at the same time Samba
enters the following text into the event log:
"""
May 20 22:43:22 fileserver-fc1 mount.smbfs[6515]: [2004/05/20 22:43:22, 0]
client/smbmount.c:do_connection(237)
May 20 22:43:22 fileserver-fc1 mount.smbfs[6515]:   6515: tree connect failed:
ERRDOS - ERRnosuchshare (You specified an invalid share name)
"""

If the client system is a Windows box, then this is effectively a fatal error
for them, as they don't recover from the hang.  If the client is a machine using
smbclient, it will hang for 20 seconds or so then permanently drop the
connection with a 'dskattr timeout' error.

The problem completely vanishes if the ext3 filesystem is mounted without the
'data=journal' option.

Comment 3 Gerald (Jerry) Carter 2005-02-07 07:12:13 UTC
This is not our bug.  if the journal on the fs causes smbd problems, 
it is an fs bug, not Samba.
Comment 4 Darryl Dixon 2005-02-20 17:23:53 UTC
Hi,

    I appreciate the feedback, and respect your position that this is not a
Samba bug.  Indeed, the primary cause of failure is the filesystem.  As such I
will leave this bug as 'closed'.  However, I would like to submit for your
consideration the observation that this is a particularly bad failure-mode for
Samba, and the link between filesystem setup and Samba failure is non-obvious at
best...

Cheers,
Darryl