Hello everybody.
My linux box is running LTSP software for "powering up" thin clients,
as well as samba package for providing disk shares for Windows (mainly
9x) clients.
Windows clients use DOS (Clipper) multi-user (i would not call it
network) program off the Samba share. Client ARE working properly in
terms of proper locking files (I turn off the oplocks for some or all
files). I mean, the application run by user_1 locks its files properly
so the app run by the user_2 is aware of these file locks.
Now I want my thin clients to be able to run the same application.
Note: working on thin clients means working on the server itself.
I am running it via Dosemu+Freedos. Of course, when I give the clients
(and thus, the server itself) real linux directory as a DOS working
directory (via 'lredir' command), Linux doesn't care for DOS/Windows
lock mechanism used by Windows clients and always grants access to the
files (.dbf and others). This leads to files corruption.
My idea was to mount the samba share as the smbfs to, let's say,
/mnt/samba , and then redirect it as DOS drive for DOSEMU.
Unfortunately, it doesn't seem to work for me, but I cannot believe it
cannot be done. I will be grateful for any ideas.
I think the problem is with local accessing the mounted smb share, but
I am not sure.
Details: Gentoo Linux, 2.6.9, Samba 3.0.8
smb.conf
[global]
dos charset = 852
unix charset = ISO8859-2
workgroup = grp
server string = Samba Server %v
interfaces = lo, eth0
bind interfaces only = Yes
map to guest = Bad User
smb passwd file = /etc/samba/private/smbpasswd
guest account = gosc
log level = 3
log file = /var/log/samba3/log.%m
max log size = 50
name resolve order = lmhosts host bcast
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
os level = 33
preferred master = Yes
domain master = Yes
dns proxy = No
kernel oplocks = No
printer admin = @wheel
hosts allow = 10.2.1.0/24, 10.1.1.0/24, 127.0.0.1
case sensitive = No
[public]
comment = Public
path = /home/samba
force user = gosc
force group = users
read only = No
force create mode = 0775
force directory mode = 0775
guest only = Yes
guest ok = Yes
blocking locks = No
oplocks = No
level2 oplocks = No
strict locking = Yes
dos filemode = Yes
dos filetimes = Yes
Then I mount it like that:
mount.smbfs //bloom/public /mnt/samba/ -o
fmask=0775,dmask=0775,uid=gosc,gid=users,guest
and when I try to write there:
touch /mnt/samba/test
there is a long delay, followed by an IO error.
During the delay smbstatus shows DENY_FCB lock :
Samba version 3.0.8
PID Username Group Machine
-------------------------------------------------------------------
Service pid machine Connected at
-------------------------------------------------------
public 9281 127.0.0.1 Tue Dec 7 19:12:58 2004
Locked files:
Pid DenyMode Access R/W Oplock Name
--------------------------------------------------------------
9281 DENY_FCB 0x3 RDWR NONE
/home/samba/test
Any ideas will be appreciated.
With regards,
Piotr Kaminski
|