Discussion:
[Samba] Share disconnect after inactivity
Andreas Schlager
20 years ago
Permalink
Hi list,

I've the strange problem, that after some time of inactivity a share is
being disconnected. This leads to a red 'X' in the Workplace's list of
connected drives. When opening a disconnected drive, the drive is being
reconnected.

BUT: This has a very fatal side-effect: When f.e. an MS-Access database
is open and the user does not use this db, the share is also being
disconnected. The connection is not restored, when the user works again
in the access-db.

My question: Is this a windows-behaviour or is this from the samba? The
disconnected drives (marked with the red 'X') I can see also on machines
connected to a Windows PDC, but no problems with access occurs there.

Many thanks in advance!

Here some snips of my smb.conf:
[global]
workgroup = LUNGOETZ
netbios aliases = LUNGOETZ1
server string = %h server (Samba %v)
passdb backend = ldapsam:ldap://127.0.0.1/
enable privileges = Yes
syslog = 0
log file = /var/log/samba/log.%m
max log size = 1000
debug uid = Yes
time server = Yes
printcap cache time = 60
printcap name = cups
add user script = /usr/local/sbin/smbldap-useradd -m "%u"
delete user script = /usr/local/sbin/smbldap-userdel "%u"
add group script = /usr/local/sbin/smbldap-groupadd -p "%g"
delete group script = /usr/local/sbin/smbldap-groupdel "%g"
add user to group script = /usr/local/sbin/smbldap-groupmod -m
"%u" "%g"
delete user from group script =
/usr/local/sbin/smbldap-groupmod -x "%u" "%g"
set primary group script = /usr/local/sbin/smbldap-usermod -g
"%g" "%u"
add machine script = /usr/local/sbin/smbldap-useradd -w "%u"
logon script = login.kix
logon drive = E:
domain logons = Yes
os level = 65
preferred master = Yes
domain master = Yes
wins support = Yes
ldap admin dn = cn=admin,dc=lun1,dc=kaindl,dc=com
ldap delete dn = Yes
ldap group suffix = ou=Groups
ldap idmap suffix = ou=Idmap
ldap machine suffix = ou=Computers
ldap passwd sync = Yes
ldap suffix = dc=lun1,dc=kaindl,dc=com
ldap ssl = no
ldap user suffix = ou=Users
utmp = Yes
remote announce = 172.16.0.4
remote browse sync = 172.16.0.4
panic action = /usr/share/samba/panic-action %d
idmap uid = 10000-19999
idmap gid = 10000-19999
template homedir = /home/samba/%D/%U
template shell = /bin/bash
admin users = xxx, yyy, zzz
printer admin = xxx, yyy, zzz
map acl inherit = Yes
acl check permissions = No
printing = cups
print command =
lpq command = %p
lprm command =
veto files = /*.eml/*.nws/*.{*}/
veto oplock files = /*doc/*.xls/*.mdb/
hide files = /Access_QS/

[IPC$]
path = /tmp

[netlogon]
comment = Network Logon Service
path = /home/samba/Netlogon
write list = administrator, aschlager, crettenbacher
guest ok = Yes
locking = No

[profiles]
comment = Profile Share
path = /home/samba/Profiles
read only = No
create mask = 0700
directory mask = 0700
profile acls = Yes

[homes]
comment = Home Directories
valid users = %U
read only = No
create mask = 0700
directory mask = 0700
browseable = No
acl group control = Yes
inherit owner = Yes
inherit permissions = Yes

[printers]
comment = All Printers
path = /tmp
create mask = 0700
printable = Yes
browseable = No

[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = Administrator, crettenbacher, aschlager, root
guest ok = Yes

[Programme]
comment = Programme
path = /home/samba/Programme
read only = No
create mask = 0770
directory mask = 0750
acl group control = Yes
inherit owner = Yes
inherit permissions = Yes

[EMail]
comment = Pegasus Mailfolder
path = /home/samba/Users/EMail
read only = No
create mask = 0700
directory mask = 0700
acl group control = Yes
inherit owner = Yes
inherit permissions = Yes

Regard,
--
M. Kaindl Holzindustrie
Kaindlstra?e 2
A-5071 Wals/Salzburg

Andreas Schlager, IT
Dmitriy Kirhlarov
20 years ago
Permalink
Hi,
Post by Andreas Schlager
Hi list,
I've the strange problem, that after some time of inactivity a share is being
disconnected. This leads to a red 'X' in the Workplace's list of connected drives.
When opening a disconnected drive, the drive is being reconnected.
look to "deadtime" option in smb.conf(5)

WBR
--
Dmitriy Kirhlarov
OILspace, 26 Leninskaya sloboda, bld. 2, 2nd floor, 115280 Moscow, Russia
P:+7 095 105 7247 ext.203 F:+7 095 105 7246 E:***@oilspace.com
OILspace - The resource enriched - www.oilspace.com
Andreas Schlager
20 years ago
Permalink
Post by Dmitriy Kirhlarov
Hi,
Post by Andreas Schlager
Hi list,
I've the strange problem, that after some time of inactivity a share is being
disconnected. This leads to a red 'X' in the Workplace's list of connected drives.
When opening a disconnected drive, the drive is being reconnected.
look to "deadtime" option in smb.conf(5)
WBR
Hi Dimitriy,

deadtime is set to "0" (= default value).
Maybe the documentation is wrong here?? (it says: "A deadtime of zero
indicates that no auto-disconnection should be performed.")

Or could it be a problem in the implementation? I've googled around and
found that windows servers (NT4 and above) have a default disconnect
time from 15 minutes. But with a windows server this wasn't a problem
for me at any time.

Regards,

-Andreas.
Dmitriy Kirhlarov
20 years ago
Permalink
Hi,
Post by Andreas Schlager
deadtime is set to "0" (= default value).
Maybe the documentation is wrong here?? (it says: "A deadtime of zero indicates that
no auto-disconnection should be performed.")
Try use 30 min. In this case we can understand -- is this option work.
Post by Andreas Schlager
Or could it be a problem in the implementation? I've googled around and found that
windows servers (NT4 and above) have a default disconnect time from 15 minutes. But
with a windows server this wasn't a problem for me at any time.
AFAIK, connection can be closed from server and from client.
Possible, you need tune your clients machines. Not samba server.

WBR
--
Dmitriy Kirhlarov
OILspace, 26 Leninskaya sloboda, bld. 2, 2nd floor, 115280 Moscow, Russia
P:+7 095 105 7247 ext.203 F:+7 095 105 7246 E:***@oilspace.com
OILspace - The resource enriched - www.oilspace.com
Continue reading on narkive:
Loading...