Re: Samba and kernel oplocks - Solved????

2002-09-11 Thread Uwe Feldtmann

Hi,
I've been following this thread in the hope that it would help with a
similar problem that I've been experiencing. Alas it doesn't help.

The scenario:
I am running a dos app from a shared samba directory on a linux server
with both windows and dosemu clients.

The problem:
When the dosemu clients start the app first, the windows clients get the
following message:-
  Cannot access the file N:\DATA\EQUITY\EQUITY.EXE.
  Make sure the file is a valid program and that it is not in use by
another program.

When the windows clients start the app first, the dosemu clients don't
have a problem accessing the program or the data.

I've applied the patch to dosemu from the previous posts on this thread
with to dosemu 1.1.3 and am using the current version of samba.
EQUITY.EXE is a clarion 2.1 based dos app that has been in use for years
on all networks tested.

Any ideas?

Yours,
Uwe.


On Tue, 2002-09-03 at 09:08, Stephen Lee wrote:
 On Wed, 2002-08-28 at 23:21, Sergey Suleymanov wrote:
   Anderson Pereira Ataides writes:
  
   Anderson I thing problem is not only samba because nfs also have
   Anderson problem. I have two Linux workstations and when I lock
   Anderson record in one of them, the other one can't see this lock.
  
   Anderson Like you I'm waiting for a solution to this problem.
  
  Well, I'm just try locks with samba, and it seems work.
  oplocks = no in smb.conf and this hack to mfs.c
  
  --- src/dosext/mfs/mfs.c.orig   Thu Aug 29 10:09:33 2002
  +++ src/dosext/mfs/mfs.cThu Aug 29 10:08:31 2002
  @@ -3823,11 +3823,16 @@
  the top two bits are set. Shift the top ones by two bits. This
  still allows OLE2 apps to operate, but should stop lockd from
  dieing */
  +#if 0
  if ((larg.l_start  mask) != 0)
  larg.l_start = (larg.l_start  ~mask) | ((larg.l_start  mask) 
 2);
  +#else
  +   larg.l_start = 0x7fff;
  +#endif
  ret = fcntl (fd,F_SETLK,larg);
  Debug0((dbg_fd, lock fd=%x rc=%x type=%x whence=%x start=%lx, 
len=%lx\n,
  fd, ret, larg.l_type, larg.l_whence, larg.l_start,larg.l_len));
  +   if (ret == -1) SETWORD((state-eax), ACCESS_DENIED);
  return ret != -1 ? TRUE : FALSE;
  }
   break;
  
  I don't understand that bit magic, maybe this won't work with
  nfs or something else.
  
 
 I'm happy to say that the above patch allows Foxpro/Dosemu file locks to
 be recognized by Samba 2.2.4. This means I can run the Foxpro
 application via Dosemu and under MSDOS/Win98/Samba simultaneously! The
 only issue I had with the above patch is that the line numbers did not
 match my version of Dosemu 1.1.3.2 with keyboard patches. I had to
 insert the lines manually.
 
 Now onto stress testing to ensure the changes do not affect Dosemu
 stability.
 
 Thanks Sergey!
 
 Stephen
 
 
 -
 To unsubscribe from this list: send the line unsubscribe linux-msdos in
 the body of a message to [EMAIL PROTECTED]
 More majordomo info at  http://vger.kernel.org/majordomo-info.html
 


-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html



Dosemu file/record locking issues - anybody solved it?

2002-09-11 Thread Michal Samek

Hi,
for some time (about year) I'm trying to reach the compatibility of the
dosemu file locking with dos/win workstations.

It's not my first post about it, I have searched the archives, google,
everything. I've tried the patches /the suggestions with no results. 

My situation:
Heterogenous network, clipper application (dbf's) running simultaneously
from dos/win and dosemu sessions, dos/win stations mount samba volumes
(samba 2.2.3, linux rh73 kernel 2.4.18, but tried a lot of combinations
in the past), dosemu uses lredired smbmounted drive. 

Problems:
1) dosemu clearly opens a file in deny-read (exclusive) mode even if
it's opened in shared mode by some win sessions. It causes that our app
crashes when starting on dosemu session.
I've never saw the sollutions for this on lredired drive.

2) dosemu session can't see the record (file range) locks put by the
dos/win session. There was a patch to some old version of Dosemu (made
by some Polish student I think) which solved it for me but it was never
sumbitted to dosemu developers or rejected by them - I dunno. The
patches which arrived last month (??) - about foxpro locking issues
which is I believe somewhat different from the clipper locking - didn't
solve the problem.

So, maybe there really exists someone who solved it in the similar
environment as I use? Thanks alot if someone can help me.

Michal Samek










-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html



Re: nwserv

2002-09-11 Thread Szabo Atti

2002, Sep 11 - Szabo Atti wrote :
 2002, Sep 10 - Stas Sergeev wrote :
  Try setting $_console=(0) and $_graphics=(0) in
  your dosemu.conf and see if it helps.
 All set to 0
Sorry, they were not set to 0.
I forgot that the graphics was set on user demand,
but i thought it was set to 0.
I try it
-- 
-
-
A t t i l a :: [EMAIL PROTECTED] :: S z a b o
-
-
-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html



Re: Dosemu file/record locking issues - anybody solved it?

2002-09-11 Thread Sergey Suleymanov

 Michal Samek writes:

 Michal So, maybe there really exists someone who solved it in the
 Michal similar environment as I use? Thanks alot if someone can help
 Michal me.

What DOS are you using under dosemu?

-- 
  Sergey Suleymanov

-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html



Re: Dosemu file/record locking issues - anybody solved it?

2002-09-11 Thread Michal Samek

On St, 2002-09-11 at 14:48, Sergey Suleymanov wrote:
  Michal Samek writes:
 
  Michal So, maybe there really exists someone who solved it in the
  Michal similar environment as I use? Thanks alot if someone can help
  Michal me.
 
 What DOS are you using under dosemu?


caldera dr-dos 7.03


 
 -- 
   Sergey Suleymanov
 
 -
 To unsubscribe from this list: send the line unsubscribe linux-msdos in
 the body of a message to [EMAIL PROTECTED]
 More majordomo info at  http://vger.kernel.org/majordomo-info.html


-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html



Re: Dosemu file/record locking issues - anybody solved it?

2002-09-11 Thread Sergey Suleymanov

 Michal Samek writes:

 Michal So, maybe there really exists someone who solved it in the
 Michal similar environment as I use? Thanks alot if someone can help
 Michal me.
   What DOS are you using under dosemu?


 Michal caldera dr-dos 7.03

Can you try MS-Dos? At the least it encounters read
error. Dr-Dos just reads some garbage.

-- 
  Sergey Suleymanov

-
To unsubscribe from this list: send the line unsubscribe linux-msdos in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html