Maximum Session IDs
Chris Tooley
ctooley at amoa.org
Thu Dec 6 06:38:03 GMT 2001
Ok, I did what you said (deleted the sessionid.tdb) after stopping the
samba service. This did in fact cause the problem to go away. Actually
it worked the miracle that samba wouldn't error out anymore at all. It
just wouldn't let anyone log in at all. Everyone was denied access. :)
Of course this being a production server I didn't really think that was
going to go over well, and wasn't sure how long it would be before you'd
get to send me another message so I re-installed Samba 2.2.2 over the
top of the already running 2.2.2 installation. Upon replacing the
smbpasswd file and restarting Samba I was able to get people logging in
again. We'll see if anything else improves.
Also, the sessionid.tdb wasn't in /var/locks/samba, there is no such
thing in my installation. There was a /var/cache/samba/ that I did
delete.
Chris Tooley
On Thu, 2001-12-06 at 07:14, Tommy Wu wrote:
> Andrew Bartlett <abartlet at pcug.org.au> wrote:
>
> > Shut down Samba, delete /var/locks/samba/sessionid.tdb.
> > Try to reproduce.
>
> I've the same problem with samba 2.2.x (all I've tried from 2.2.1).
> I've only 3 client here, but after one day, the session id will over 3000... :-(
>
> > Turn up the log level, and give me a some logs of the code just before
> > it thinks its out of sessionids.
>
> I add some debug code to session_claim() and session_yield() to mark a session allocate
> and session release.
>
> I found when I running a Win2000 server as samba client...
> It'll request a new session id for a few seconds like
>
> [2001/12/06 20:52:55, 1] smbd/session.c:session_claim(93)
> session_claim: allocate ID: 1
> [2001/12/06 20:52:55, 1] smbd/service.c:make_connection(610)
> teatime-dc (192.168.0.10) connect to service BBS_SYS as user bbs (uid=1001, gid=1000) (pid 19408)
> [2001/12/06 20:53:00, 1] smbd/session.c:session_claim(93)
> session_claim: allocate ID: 2
> [2001/12/06 20:53:00, 1] smbd/service.c:make_connection(610)
> teatime-dc (192.168.0.10) connect to service BBS_SYS as user bbs (uid=1001, gid=1000) (pid 19408)
> [2001/12/06 20:53:02, 1] smbd/session.c:session_claim(93)
> session_claim: allocate ID: 3
> [2001/12/06 20:53:02, 1] smbd/service.c:make_connection(610)
> bbs (192.168.0.129) connect to service BBS_SYS as user bbs (uid=1001, gid=1000) (pid 19423)
> [2001/12/06 20:53:03, 1] smbd/service.c:close_cnum(650)
> teatime-dc (192.168.0.10) closed connection to service BBS_SYS
>
> There is only one client here, should only one session id here I think.
> But for a few seconds, a win2000 server smbclient request a new session id..
> So the session id will run over the limit (3000).
>
> When I kill the process in smbstatus (only one process)...
> All session id will release like this:
>
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 50
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 49
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 48
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 47
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 46
> [2001/12/06 21:01:26, 1] smbd/session.c:session_yield(148)
> session_yield: release ID: 2
>
> I'm using Debian woody now. for kernel 2.4.2 to 16 with reiserfs and xfs.
> (with or without smp) All will get the same problem here.
>
> Attach file is a samba log for log level = 10.
>
> I current patch the samba source to disable session_claim() and session_yield().
> This seems work fine here.... (I'm not sure there is any other problem without
> these two functions...)
>
> --
>
> Tommy Wu
> mailto:tommy at teatime.com.tw
> http://www.teatime.com.tw/~tommy
> ICQ: 22766091
> Mobile Phone: +886 936 909490
> TeaTime BBS +886 2 31515964 24Hrs V.Everything
>
More information about the samba
mailing list