smbd blocking in receive_smb

Eric Horst erich at cac.washington.edu
Mon Jul 15 15:54:02 GMT 2002


Hello, I'm tracking down an issue that we've been suffering with for some
time.  Before I invest too much time in trying to reason through how it
works I thought I'd ask if anybody else knows of issues in this area or
knows of the problem.

The visible symptom is that users find themselves locked out of files by
their own processes.  On the server side we find that users have multiple
smbd's running that are talking to the same PC.  One smbd will be the
active one and others (older ones) will be blocked and will not respond to
SIGTERM.  Killing with other signals works, but leaves old locks in the
lock database.

Below I've included a sample of four processes shown in smbstatus output
and the gdb backtrace of each of the four.  Three of them are blocked in
read_data and not being responsive to the client PC anymore.  Clearly, as
each of these processes blocked the client PC happily started a new one.

The smbd version is 2.2.5 on Linux, Redhat 7.2.

I realize that everyone is working on more exciting aspects of Samba but
wonder if anybody more familiar with the util_sock.c routines and
signalling would have ideas or hints for me to debug further.  The receive
code gets twisty and I'm not sure I totally understand how it's supposed
to be working with keepalive packets and such.

--Eric



% smbstatus
trans    yi    users  7382   fsn_ufo (x.x.x.201) Mon Jul 15 12:33:50 2002
trans    yi    users  8974   fsn_ufo (x.x.x.201) Mon Jul 15 13:59:34 2002
trans    yi    users  9020   fsn_ufo (x.x.x.201) Mon Jul 15 14:00:26 2002
trans    yi    users  9253   fsn_ufo (x.x.x.201) Mon Jul 15 14:09:45 2002


Process 7381 (stuck)

#0  0x401451a4 in __libc_read () from /lib/libc.so.6
#1  0x00003904 in ?? ()
#2  0x0813a5a2 in read_data ()
#3  0x0813aad5 in receive_smb ()
#4  0x080a0670 in receive_message_or_smb ()
#5  0x080a181d in smbd_process ()
#6  0x0806a1d9 in main ()
#7  0x40088306 in __libc_start_main (main=0x8069a4c <main>, argc=2,
    ubp_av=0xbfffe654, init=0x8067f90 <_init>, fini=0x8151720 <_fini>,
    rtld_fini=0x4000d2dc <_dl_fini>, stack_end=0xbfffe64c)
    at ../sysdeps/generic/libc-start.c:129


Process 8974 (stuck)

#0  0x401451a4 in __libc_read () from /lib/libc.so.6
#1  0x00003904 in ?? ()
#2  0x0813a5a2 in read_data ()
#3  0x0813aad5 in receive_smb ()
#4  0x080a0670 in receive_message_or_smb ()
#5  0x080a181d in smbd_process ()
#6  0x0806a1d9 in main ()
#7  0x40088306 in __libc_start_main (main=0x8069a4c <main>, argc=2,
    ubp_av=0xbfffe654, init=0x8067f90 <_init>, fini=0x8151720 <_fini>,
    rtld_fini=0x4000d2dc <_dl_fini>, stack_end=0xbfffe64c)
    at ../sysdeps/generic/libc-start.c:129


9020   (stuck)

#0  0x401451a4 in __libc_read () from /lib/libc.so.6
#1  0x00003904 in ?? ()
#2  0x0813a5a2 in read_data ()
#3  0x0813aad5 in receive_smb ()
#4  0x080a0670 in receive_message_or_smb ()
#5  0x080a181d in smbd_process ()
#6  0x0806a1d9 in main ()
#7  0x40088306 in __libc_start_main (main=0x8069a4c <main>, argc=2,
    ubp_av=0xbfffe654, init=0x8067f90 <_init>, fini=0x8151720 <_fini>,
    rtld_fini=0x4000d2dc <_dl_fini>, stack_end=0xbfffe64c)
    at ../sysdeps/generic/libc-start.c:129


Process  9253  (the most recently started and active)

#0  0x4014c5be in __select () from /lib/libc.so.6
#1  0xbfffe0e0 in ?? ()
#2  0x080a05ad in receive_message_or_smb ()
#3  0x080a181d in smbd_process ()
#4  0x0806a1d9 in main ()
#5  0x40088306 in __libc_start_main (main=0x8069a4c <main>, argc=2,
    ubp_av=0xbfffe654, init=0x8067f90 <_init>, fini=0x8151720 <_fini>,
    rtld_fini=0x4000d2dc <_dl_fini>, stack_end=0xbfffe64c)
    at ../sysdeps/generic/libc-start.c:129







More information about the samba-technical mailing list