* More whine about locking
@ 2002-11-24 20:57 Siim Vahtre
2002-11-25 0:30 ` Bart Oldeman
0 siblings, 1 reply; 10+ messages in thread
From: Siim Vahtre @ 2002-11-24 20:57 UTC (permalink / raw)
To: linux-msdos
Hi again.
Many weeks have passed but problem is still there.
No matter how I mount the disk or what 'layers' there are - dosemu
seem to NEVER care about the locks made by Windows clients or by
other dosemu clients. And I am not talking about database locking or
something. NC's "edit" and "view" doesn't lock files either.
I think I've tried everything now.
The disk they are sharing have been mounted with NFS, SMB, NetWare
and even directly(psyhical drive). None of them made any difference.
No locking whatsoever.
I also tried different OSes (DrDos and FreeDOS) - no luck.
Only lock that I was able to get was "DenyMode: DENY_NONE | Oplock: NONE"
which is quite useless and didn't stop anyone to edit one file twice.
Tried dosemu versions were (1.0.2), (1.1.3) and (1.1.3.7)
Kernel(vanilla) is 2.4.19
ANY help to get this locking working is appreciated.
I really don't know what to try next :(
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-24 20:57 Siim Vahtre
@ 2002-11-25 0:30 ` Bart Oldeman
2002-11-25 15:06 ` Siim Vahtre
0 siblings, 1 reply; 10+ messages in thread
From: Bart Oldeman @ 2002-11-25 0:30 UTC (permalink / raw)
To: Siim Vahtre; +Cc: linux-msdos
On Sun, 24 Nov 2002, Siim Vahtre wrote:
> Many weeks have passed but problem is still there.
Try the assembly program below and assemble using
nasm lockdos.asm -o lockdos.com
copy lockdos.com and lockdos.asm to the same directory.
Run two DOSEMU instances.
In one of them, run lockdos.
This will let you select how to lock lockdos.asm
In the other one, try
type lockdos.asm
In my experiment, with C: lredir'ed to an ext2 partition,
using option 1 and 3, the "type" refused to read the file.
So file locking works, right? I'm just not sure what I'm missing here.
Bart
org 100h
xor bx, bx
lop:
mov ah, 9
mov dx, string
int 21h
mov ah, 1
int 21h
sub al, '0'
cmp al, 5
jae quit
push ax
or bx, bx
jz dontclose
mov ah, 3eh
int 21h ; close file
dontclose:
pop ax
shl al, 4
or al, 2
mov dx, filename
mov ah, 3dh
int 21h ; open r/w
mov bx, ax
jmp short lop
quit:
ret
string db 13,10,'Enter locking mode: ', 13, 10
db '0: compatibility', 13, 10,
db '1: DENYALL', 13, 10,
db '2: DENYWRITE', 13, 10,
db '3: DENYREAD', 13, 10,
db '4: DENYNONE', 13, 10,
db '5: quit', 13, 10, '$'
filename db 'lockdos.asm', 0
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 0:30 ` Bart Oldeman
@ 2002-11-25 15:06 ` Siim Vahtre
2002-11-25 15:29 ` Bart Oldeman
0 siblings, 1 reply; 10+ messages in thread
From: Siim Vahtre @ 2002-11-25 15:06 UTC (permalink / raw)
To: linux-msdos
> So file locking works, right? I'm just not sure what I'm missing here.
Thank you for your reply.
I regret to announce that this program prove what I already said in first
mail in this thread - no locking whatsoever.
I tried all of those locking types. Even when I switched to DENY_ALL with
this asm program, I was still able to read, write, delete etc the file.
(And with 'smbstatus' I saw only "DENY_NONE" all the time.)
The disk they share is ext3 fs mounted with lredir.
I also tried disk mounted via samba, NFS, NC and so on. No luck :(
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 15:06 ` Siim Vahtre
@ 2002-11-25 15:29 ` Bart Oldeman
2002-11-25 15:39 ` Siim Vahtre
0 siblings, 1 reply; 10+ messages in thread
From: Bart Oldeman @ 2002-11-25 15:29 UTC (permalink / raw)
To: Siim Vahtre; +Cc: linux-msdos
On Mon, 25 Nov 2002, Siim Vahtre wrote:
> > So file locking works, right? I'm just not sure what I'm missing here.
>
> I tried all of those locking types. Even when I switched to DENY_ALL with
> this asm program, I was still able to read, write, delete etc the file.
> (And with 'smbstatus' I saw only "DENY_NONE" all the time.)
Hmm, so you get something else than I did?
did you?
a) use 1.1.3.7
b) only press the number, not the enter key (not leaving the program while
locking!)
c) use two local dosemu sessions?
Please don't play with Samba now: I just can't explain why we have
different results.
Bart
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 15:29 ` Bart Oldeman
@ 2002-11-25 15:39 ` Siim Vahtre
2002-11-25 16:52 ` Bart Oldeman
0 siblings, 1 reply; 10+ messages in thread
From: Siim Vahtre @ 2002-11-25 15:39 UTC (permalink / raw)
To: linux-msdos
> Hmm, so you get something else than I did?
> did you?
> a) use 1.1.3.7
Yes!
> b) only press the number, not the enter key (not leaving the program while
> locking!)
Yes!
> c) use two local dosemu sessions?
Yes!
> Please don't play with Samba now: I just can't explain why we have
> different results.
Ok. Pure ext3 mounted with lredir.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 15:39 ` Siim Vahtre
@ 2002-11-25 16:52 ` Bart Oldeman
2002-11-25 18:14 ` Siim Vahtre
0 siblings, 1 reply; 10+ messages in thread
From: Bart Oldeman @ 2002-11-25 16:52 UTC (permalink / raw)
To: Siim Vahtre; +Cc: linux-msdos
On Mon, 25 Nov 2002, Siim Vahtre wrote:
> > c) use two local dosemu sessions?
> Yes!
>
> > Please don't play with Samba now: I just can't explain why we have
> > different results.
> Ok. Pure ext3 mounted with lredir.
Ok.
Try the following:
have lockdos.com and lockdos.asm in the same directory.
run lockdos
press the 1 key
switch to another window
type in Linux:
lsof | grep lockdos.asm
you should get something like this:
dosemu.bi 14725 enbeo 16uw REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
now go back to the dosemu, press 2 and lsof should give you:
dosemu.bi 14725 enbeo 16ur REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
the r and w disappear for 0 and 4; for 3 you should also get a "w".
Bart
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 16:52 ` Bart Oldeman
@ 2002-11-25 18:14 ` Siim Vahtre
2002-11-25 19:54 ` Bart Oldeman
0 siblings, 1 reply; 10+ messages in thread
From: Siim Vahtre @ 2002-11-25 18:14 UTC (permalink / raw)
To: Bart Oldeman; +Cc: linux-msdos
> you should get something like this:
>
> dosemu.bi 14725 enbeo 16uw REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
>
> now go back to the dosemu, press 2 and lsof should give you:
> dosemu.bi 14725 enbeo 16ur REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
>
> the r and w disappear for 0 and 4; for 3 you should also get a "w".
_ALL_ locking modes showed:
dosemu.bi 735 siim 7u REG 3,2 579 473061 /home/siim/dosemu/freedos/lockdos.asm
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 18:14 ` Siim Vahtre
@ 2002-11-25 19:54 ` Bart Oldeman
2002-11-25 20:20 ` Siim Vahtre
0 siblings, 1 reply; 10+ messages in thread
From: Bart Oldeman @ 2002-11-25 19:54 UTC (permalink / raw)
To: Siim Vahtre; +Cc: linux-msdos
On Mon, 25 Nov 2002, Siim Vahtre wrote:
> > you should get something like this:
> >
> > dosemu.bi 14725 enbeo 16uw REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
> >
> > now go back to the dosemu, press 2 and lsof should give you:
> > dosemu.bi 14725 enbeo 16ur REG 3,7 585 1104103 /home/enbeo/dosemu/freedos/lockdos.asm
> >
> > the r and w disappear for 0 and 4; for 3 you should also get a "w".
>
> _ALL_ locking modes showed:
>
> dosemu.bi 735 siim 7u REG 3,2 579 473061 /home/siim/dosemu/freedos/lockdos.asm
Right, the only thing I can think of now that could make a difference is
the DOS kernel. I know that older FreeDOS kernels (inc. 2024c) did not
honour these locking bits. Did you try FreeDOS kernel 2027? See
http://freedos.sourceforge.net
If that still doesn't work then please send me (privately) the boot.log
from using dosemu -D+Dd, where you just enter lockdos, press 1 and exit
the emulator.
Bart
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
2002-11-25 19:54 ` Bart Oldeman
@ 2002-11-25 20:20 ` Siim Vahtre
0 siblings, 0 replies; 10+ messages in thread
From: Siim Vahtre @ 2002-11-25 20:20 UTC (permalink / raw)
To: Bart Oldeman; +Cc: linux-msdos
> Right, the only thing I can think of now that could make a difference is
> the DOS kernel. I know that older FreeDOS kernels (inc. 2024c) did not
> honour these locking bits. Did you try FreeDOS kernel 2027? See
> http://freedos.sourceforge.net
Switched 2024c to 2027.
And _IT WORKS!!_
Even region locking! I mean.. whoa :-)
Thank you!!
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: More whine about locking
@ 2002-11-26 17:16 Uwe (Peter) Feldtmann
0 siblings, 0 replies; 10+ messages in thread
From: Uwe (Peter) Feldtmann @ 2002-11-26 17:16 UTC (permalink / raw)
To: linux-msdos
Having same problems but am not using freedos.
Willing to give it a go though.
A complete 1.1.3 dosemu with up-to-date freedos would be a great help.
Is there such a thing?
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2002-11-26 17:16 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-11-26 17:16 More whine about locking Uwe (Peter) Feldtmann
-- strict thread matches above, loose matches on Subject: below --
2002-11-24 20:57 Siim Vahtre
2002-11-25 0:30 ` Bart Oldeman
2002-11-25 15:06 ` Siim Vahtre
2002-11-25 15:29 ` Bart Oldeman
2002-11-25 15:39 ` Siim Vahtre
2002-11-25 16:52 ` Bart Oldeman
2002-11-25 18:14 ` Siim Vahtre
2002-11-25 19:54 ` Bart Oldeman
2002-11-25 20:20 ` Siim Vahtre
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox