I have a single Linux server running SuSE 9.1 and Samba 3.04. I have one share that has several MS Access tables on it. One user can operate just fine, however when a second+ user tries to access the same database tables, one of several things happens depending on what I have in the smb.conf file. It's usually a permission denied, or a "can't lock" type of error. When the first user opens a table, a file called xxx.ldb gets created, where xxx is the name of the table. The lock file is owned by the user and has permissions of 644. When a second user tries to open the same table, the error occurs. In my smb.conf file, I have tried almost every option I can find that would apply to file locking, including turning on and off kernel oplocks, level2 oplocks, oplocks, and setting veto oplock files to /.ldb/.mdb/ and all possible permutations of all of them. Nothing really changes with any of them. If I force the lock file to 666, Access hangs. When this was a WinXP server, all of this worked just fine. There is something about the .ldb file that must be accessable by n+1 users. Anybody have an Access DB setup on a Samba share? How did you do it? Below is my smb.conf file (in it's present state): [global] workgroup = TESORO printing = cups printcap name = cups printcap cache time = 750 cups options = raw printer admin = @ntadmin, root, administrator username map = /etc/samba/smbusers map to guest = Bad User logon path = \\%L\profiles\.msprofile logon drive = P: logon home = \\%L\%U\.9xprofile security = user encrypt passwords = yes server string = Samba Server add machine script domain master = false domain logons = no local master = no preferred master = auto load printers = no ldap suffix = dc=example,dc=com [access] available = yes browseable = yes comment create mask = 0666 force directory mode = 0777 guest ok = no path = /shared/Access/ printable = no veto oplock files = /*.mdb/*.xls/*.ldb oplocks = no level2 oplocks = no kernel oplocks = no read only = no [shared] available = yes browseable = yes comment create mask = 0644 guest ok = no path = /shared printable = no read only = no Thanks - Dan
Guess I didn't provide enough details. Each user has his/her own copy of the database (forms, linked tables, queries, etc.). The tables in each are just links to the real tables which reside on a Samba share. Yes, Access creates the .ldb lock file. On a Windows server, this translated into just one lock file per table, no matter how many users are acessing that table. There is also a lock file per database, i.e. the database Customers.mdb, when active, has an lock file called Customers.ldb (on the local machine), and uses the linked database tables on the shared drive called SalesTables.mdb which also has a lock file called SalesTables.ldb. No matter how many users are accessing SalesTables.mdb on the shared drive, there is only one lock file. Like I said before, this all works flawlessly on a Windows server. So, what I need to figure out is how to have Samba mimic exactly what WinXP does for permissions on a network share. Dan Chris Jones wrote:>Hm its generally not a good idea to have more then 1 user inside an access >database. It can cause data corruption. The work around for something like >this is to do a front end/back end type system. IE put all the forms and >reports in one database give both users or all users a copy of this then use >linked tables to link them to the data in the background. The ldb file is >not created by samba and so these fellas prob won't be able to help ya. I >can't explain why it worked in XP it shouldn't have. the ldb file is >access's locked database file meaning someone else has it open for writing. > >Chris > > >Dan
From: Dan Weisenstein <dan@tesoro.com> To: samba@lists.samba.org Subject: [Samba] Samba + MS Access Date: Tue, 15 Jun 2004 11:42:50 -0700 ----- Original Message Follows -----> I have a single Linux server running SuSE 9.1 and Samba > 3.04. I have one share that has several MS Access tables > on it. One user can operate just fine, however when a > second+ user tries to access the same database tables, > one of several things happens depending on what I have in > the smb.conf file. It's usually a permission denied, or a > "can't lock" type of error. > > When the first user opens a table, a file called xxx.ldb > gets created, where xxx is the name of the table. The > lock file is owned by the user and has permissions of > 644. When a second user tries to open the same table, the > error occurs. In my smb.conf file, I have tried almost > every option I can find that would apply to file locking, > including turning on and off kernel oplocks, level2 > oplocks, oplocks, and setting veto oplock files to > /.ldb/.mdb/ and all possible permutations of all of them. > Nothing really changes with any of them. If I force the > lock file to 666, Access hangs. >I saw this in a Samba book by Gary Wilson. Maybe it will help (p83): "To configure a share for [Access] database that is readable by all users but can be modified by a few users ... " [share] path = /path/to/share read only = yes write list = user1, user2, @sales create mask = 0666 directory mask = 0777 force create mode = 0666 force directory mode = 0777 oplocks = no veto oplock files = /*.mdb/*.MDB/*.ldb/*.LDB/ dos filetimes = yes It was for Samba 2.2 but maybe it will help.