Deadlock with libsmbclient functions and Multiple forked processes

Akshay V Rao avrao at
Thu Jun 12 20:08:22 GMT 2003

I am currently developing a program that forks N Processes.  Each child
forked process, executes a while loop in which the following function calls
are issued in the following order: smbc_open(), smbc_read(), smbc_close().
It appears that these functions are responsible for creating deadlocks when
there exist more than one child forked process (N > 1).  If I comment out
the function calls and run the program with multiple processes, the
deadlock is gone and the program runs normally.  If I then uncomment the
function calls and run the program with only one process, the deadlock is
gone as well.  I am running Samba version 2.2.7a on RedHat 7.3 kernel
version 2.4.7-10smp, 512 Mb RAM, Dual PIII.  If anyone has any ideas, they
would definitly be greatly appreciated.

Thank you,

More information about the samba-technical mailing list