Too many session users??
andrew morgan
morgan at orst.edu
Thu Nov 16 17:22:45 GMT 2000
Quick background: Samba 2.0.7 running on Solaris 2.6
I'm seeing an interesting error in my samba log files:
[2000/11/15 23:53:40, 1] smbd/password.c:add_session_user(299)
Too many session users??
[2000/11/15 23:53:40, 1] smbd/password.c:add_session_user(299)
Too many session users??
[2000/11/15 23:53:41, 1] smbd/password.c:add_session_user(299)
Too many session users??
[2000/11/15 23:53:41, 1] smbd/service.c:make_connection(550)
cnlite2 (128.193.168.89) connect to service shenvi as user shenvi (uid=19926, gid=50) (pid 5270)
cnlite2 is a Windows 2000 Terminal Server, with (obviously) many users
connecting to the samba server through it. The users are mounting their
home directories from the server. So, for example, smbstatus will show:
rigo rigo user 22990 cnlite2 (128.193.168.89) Thu Nov 16 08:46:58 2000
beggerly beggerly user 22990 cnlite2 (128.193.168.89) Thu Nov 16 08:47:49 2000
tzanetio tzanetio user 22990 cnlite2 (128.193.168.89) Thu Nov 16 08:50:08 2000
constand constand user 22990 cnlite2 (128.193.168.89) Thu Nov 16 08:56:01 2000
The error only happens when there are a lot of connections through the
terminal server.
Digging through the source shows that the error I'm seeing is generated in
source/smbd/password.c:
/****************************************************************************
add a name to the session users list
****************************************************************************/
void add_session_user(char *user)
{
fstring suser;
StrnCpy(suser,user,sizeof(suser)-1);
if (!Get_Pwnam(suser,True)) return;
if (suser && *suser && !in_list(suser,session_users,False))
{
if (strlen(suser) + strlen(session_users) + 2 >= sizeof(pstring))
DEBUG(1,("Too many session users??\n"));
else
{
pstrcat(session_users," ");
pstrcat(session_users,suser);
}
}
}
where a pstring is:
typedef char pstring[1024];
Has anyone else seen this error with Windows 2000 Terminal Server? I've
also seen multiple user's connections from a regular Windows 2000
Professional desktop machine which is shared by multiple users. It seems
like W2K doesn't close the connection completely when a user logs out.
Is this error message something I should be worried about? What is the
session_users string used for?
I'm also worried by the amount of free shared memory reported by
smbstatus:
Share mode memory usage (bytes):
289944(27%) free + 687064(65%) used + 71568(6%) overhead = 1048576(100%) total
This is shortly after restarting samba, with about 170 connections. My
other samba servers rarely fall below 95% free shared memory, although
they don't have anywhere near as many connections or open files. What is
shared memory used for? Should I be concerned by this?
Thanks,
Andy
More information about the samba-technical
mailing list