VOGONS


First post, by dale5351

User metadata
Rank Newbie
Rank
Newbie

I have a new EeePc with default Xandros linux installed. I have installed dosbox in order to run one of my favored DOS applications. It runs quite well except for one strange problem.

The application is called BlueWave, which reads QWK mail packets for messaging offline on BBSes. The application is fairly old, abandonware, but I have a paid registration -- and it works perfectly well running in a DOS window on my XP machine (actually I use 4NT, not DOS -- but think that is irrelevant to the problem).

The specific problem is that at one step, Bluewave spawns a call to a compression program (i.e. pkzip). The specific call is listed in a configureation file as
d:\util\pkzip.exe -ex @F @I
Running on XP, this works fine.
But on the linux system something goes wrong. As a result of substituting a batch file for the direct call to pkzip, I have determined the problem -- but not a solution.

What goes wrong seems to be that the Bluewave program on the linux system carries on doing its thing after spawning off the call to the batch file that runs the pkzip -- and its next step is to delete the files that were going to be packed up by pkzip. On the XP machine, this does not happen and the files are there to be zipped. On the linux machine they are gone before the batch file can process them.

Any suggestions?

Reply 1 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

Just to be sure - you DO have a D-drive mounted in DOSBox, and it has the \UTIL directory and the PKZIP.EXE in it?

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 2 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie

Thanks for the very quick response.

Yes, I have mounted the D and H drives needed. pkzip is in the proper place in d:\util, and does get called ok. I substituted a bat file to manage the call and look at contents of directories, and that is how I proved to myself that the file needed had disappeared before pkzip got a chance to pack it up.

Since my original post, I have done two more relevant experiments. I installed DOSBOX onto my XP machine and also got it configured with the appropriate mount commands. Both version 0.65 (which is what was installed on Xandros system) and version 0.72 have the same behavior as on the XP machine as on the Xandros machine -- namely that the file has disappeared before pkzip gets a chance to pack it up. That does not happen when I run the program Bluewave directly in an XP dos window.

There seems to be something different about how DOSBOX handles the spawning of a program and how XP does it.

Reply 3 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

Hmmm. Okay, a wild guess. Maybe PKZIP is assuming some C:\TMP or C:\TEMP or %TEMP% directory somewhere during the unpacking procedure? And if that directory does not exists, it silently fails?

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 4 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

Tried an older (or newer) version of PKZIP?

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 5 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

pktmp ?

ftp://ftp.rit.edu/pub/windows/pkzip/hints.txt

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 6 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie

I am quite certain that the problem is not in pkzip itself, but in the fact that the file is being deleted by bluewave before pkzip can pack it up --- and that should not happen until after the pkzip call.

I have the ability to push to DOS from within bluewave. If I do that, and then do a "dir" on the relevant directory, the file exists at that time. I then return to bluewave, and do the operation that causes the call to the batch file. The first thing that batch file does is "dir" on the relevant directory, and the relevant file is gone. Then the call to pkzip is made, and it echos "nothing to do" or something like that.

I don't seem to have the ability to do a cut and paste from the DOSBOX dos window like I do in a normal DOS Window on XP, or I'd show you the results of the dir commands.

Reply 9 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie

Thanks for the continued interest.
First, here is the current version of the batch file which directs the outputs to a file called file.txt. Batch file is called myzip.bat and is located on the path in a directory d:\util
-- myzip.bat --

echo off
echo %1 >> file.txt
echo %2 >> file.txt
pause
dir h:\bwave\work >> file.txt
pause
dir h:\bwave\reply >> file.txt
pause
pkzip -ex %1 %2 >> file.txt
pause

-- end of myzip.bat --
And now comes the output that was sent to file.txt. I have annotated it with some comments. Everything I added has beginning of the line set to *COMMENT -- <some text>
Sorry for the length of it.
-- file.txt --
*COMMENT -- push to DOS and DIR of the relevant directory
*COMMENT -- notice that file OWL.XTI exists.

Directory of H:\BWAVE\WORK\.
. <DIR> 06-04-2008 1:02
.. <DIR> 06-04-2008 1:03
020 NDX 205 06-04-2008 1:02
067 NDX 30 06-04-2008 1:02
157 NDX 50 06-04-2008 1:02
213 NDX 5 06-04-2008 1:02
CONTROL DAT 1,165 06-04-2008 1:02
DOOR ID 120 06-04-2008 1:02
MESSAGES DAT 151,296 06-04-2008 1:02
OWL INF 7,230 06-04-2008 1:02
OWL XTI 116 06-04-2008 1:02
_RESTART BW~ 607 06-04-2008 1:02
10 File(s) 160,824 Bytes.
2 Dir(s) 110,540,800 Bytes free.

*COMMENT -- below is the output caused by the batch file
*COMMENT -- that does the compression and does the
*COMMENT -- error dumps of directories
*COMMENT -- first that batch file echos the two parameters
*COMMENT -- which are the zip file (named OWL.821)
*COMMENT -- and the file to be compressed into it (OWL.XTI).

H:\QMODEM\DOWNLOAD\MAIL\OWL.821
H:\BWAVE\WORK\OWL.XTI

*COMMENT -- then the batch file does DIR on the
*COMMENT -- relevant directory. Notice that
*COMMENT -- OWL.XTI is no longer there.

Directory of H:\BWAVE\WORK\.
. <DIR> 06-04-2008 1:02
.. <DIR> 06-04-2008 1:03
020 NDX 205 06-04-2008 1:02
067 NDX 30 06-04-2008 1:02
157 NDX 50 06-04-2008 1:02
213 NDX 5 06-04-2008 1:02
CONTROL DAT 1,165 06-04-2008 1:02
DOOR ID 120 06-04-2008 1:02
MESSAGES DAT 151,296 06-04-2008 1:02
OWL INF 7,230 06-04-2008 1:02
8 File(s) 160,101 Bytes.
2 Dir(s) 110,540,800 Bytes free.

*COMMENT -- this is directory I wanted to look at, not really relevant

Directory of H:\BWAVE\REPLY\.
. <DIR> 06-04-2008 1:02
.. <DIR> 06-04-2008 1:03
OWL BW~ <DIR> 06-04-2008 1:02
0 File(s) 0 Bytes.
3 Dir(s) 110,540,800 Bytes free.

*COMMENT -- and here we have directed the PKZIP output
*COMMENT -- to this file

PKZIP (R)   FAST!   Create/Update Utility   Version 2.50   03-01-1999
Copr. 1989-1999 PKWARE Inc. All Rights Reserved. Shareware Version
PKZIP Reg. U.S. Pat. and Tm. Off. Patent No. 5,051,745

þ 80486 CPU detected.
þ Using 16-Bit Real Mode Maximum Compression.

Updating ZIP: H:/QMODEM/DOWNLOAD/MAIL/OWL.821

PKZIP: (E12) nothing to do!

*COMMENT -- and since the file has disappeared, pkzip says
*COMMENT -- nothing to do.
*COMMENT -- below are calls made when the program BWAVE
*COMMENT -- is exiting. By then it has cleared out
*COMMENT -- the WORK directory.

H:\QMODEM\DOWNLOAD\MAIL\OWL.REP
H:\BWAVE\REPLY\OWL.BW~\*.*
Directory of H:\BWAVE\WORK\.
. <DIR> 06-04-2008 1:02
.. <DIR> 06-04-2008 1:03
0 File(s) 0 Bytes.
2 Dir(s) 110,540,800 Bytes free.
Directory of H:\BWAVE\REPLY\.
. <DIR> 06-04-2008 1:02
.. <DIR> 06-04-2008 1:03
OWL BW~ <DIR> 06-04-2008 1:03
0 File(s) 0 Bytes.
3 Dir(s) 110,540,800 Bytes free.

PKZIP (R) FAST! Create/Update Utility Version 2.50 03-01-1999
Copr. 1989-1999 PKWARE Inc. All Rights Reserved. Shareware Version
PKZIP Reg. U.S. Pat. and Tm. Off. Patent No. 5,051,745

þ 80486 CPU detected.
þ Using 16-Bit Real Mode Maximum Compression.

Creating ZIP: H:/QMODEM/DOWNLOAD/MAIL/OWL.REP
Adding: OWL.MSG Deflating % 00 (54%), done.

*COMMENT -- again a call packing up the reply packet,
*COMMENT -- seems to work ok, not relevant to the problem
*COMMENT -- of the missing OWL.XTI .
-- file.txt --

Hope that one of you can see what I mean. When I do the same thing on my windows XP machine in a normal CMD window, the OWL.XTI file is still sitting in the WORK directory when the batch is called. It does not get ridded until after that call to the compression batch file is finished.

It looks like DOSBOX is allowing a multi-thread to happen, i.e. spawning off the compression batch and immediately returning to the main program which then carries on. If so, that is the reason for the error.

Reply 10 of 45, by ADDiCT

User metadata
Rank Oldbie
Rank
Oldbie

I didn't check your batch file in detail (TLTR), but your problem could be related to an effect that has been fixed in DOSBox CVS:

2008-03-12 18:45 c2woody

* src/dos/dos.cpp: fix tsr return code handling

Try the AEP CVS build, it should contain the fix.

I don't think the problem has anything to do with "Multitasking". When you're running DOSBox, you're running a "single-tasking-OS" (that's not 100% correct in technical terms, but a good enough description) inside a multi-tasking environment, so the programs running inside DOSBox will run "one after another", just like in DOS.

I've had some strange effects with piping/redirection (>, >>) inside DOSBox in the past, but i can't remember what the effects were in detail. You could try to run 4DOS (now open source, and free) before running your app, or starting it with the batches your app is using. The whole redirection stuff would then be handled by 4DOS' functions.

P.S.: another thought - i'm no linux user, but i know that a lot of problems can be caused by incorrect file/directory permissions. Are you sure the permissions of the user running DOSBox are set correctly? To test if the problem is permission-related, run DOSBox as root.

Reply 11 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

dale - I edited your post a bit, wrapping the code segments. I think it makes it more readable.

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 12 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie

Thanks -- it does make it more readable.
forum question: How do you quote a message, and what controls did you type to do the CODE boxes?

Reply 13 of 45, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

Quotation icon on the upper-right hand side.

use:

[*code] and [*/code]

Remove the asterisks

Last edited by DosFreak on 2008-04-06, 19:59. Edited 2 times in total.

How To Ask Questions The Smart Way
Make your games work offline

Reply 14 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie
ADDiCT wrote:

I didn't check your batch file in detail (TLTR), but your problem could be related to an effect that has been fixed in DOSBox CVS:

2008-03-12 18:45 c2woody

* src/dos/dos.cpp: fix tsr return code handling

Try the AEP CVS build, it should contain the fix.

The cvs did not make any difference.

I don't think the problem has anything to do with "Multitasking". When you're running DOSBox, you're running a "single-tasking-OS" (that's not 100% correct in technical terms, but a good enough description) inside a multi-tasking environment, so the programs running inside DOSBox will run "one after another", just like in DOS.

That is what I would have thought. But there may be something strange in the way that this program (bwave) handles the calls to external programs or batch files.

I've had some strange effects with piping/redirection (>, >>) inside DOSBox in the past, but i can't remember what the effects were in detail. You could try to run 4DOS (now open source, and free) before running your app, or starting it with the batches your app is using. The whole redirection stuff would then be handled by 4DOS' functions.

I have 4DOS and 4NT, but don't see how that might help here. It is not a problem with piping or redirection.

P.S.: another thought - i'm no linux user, but i know that a lot of problems can be caused by incorrect file/directory permissions. Are you sure the permissions of the user running DOSBox are set correctly? To test if the problem is permission-related, run DOSBox as root.

I sort of did that test when I ran DOSBOX on my XP system. I'm getting the same effect there.

Thanks for trying to help.

Reply 15 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie
DosFreak wrote:
Quotation icon on the upper-right hand side. […]
Show full quote

Quotation icon on the upper-right hand side.

use:

 and 

Oh, you mean that little bitty thing that I did not realize was there :-}}

Got it now. Thanks.

Reply 16 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

You don't have any kind of anti-virus running on that Linux box? Something that might remove the file behind the scenes?

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 17 of 45, by MiniMax

User metadata
Rank Moderator
Rank
Moderator

Does the problem also happen when you run it is DOSBox on XP?

DOSBox 60 seconds guide | How to ask questions
_________________
Lenovo M58p | Core 2 Quad Q8400 @ 2.66 GHz | Radeon R7 240 | LG HL-DT-ST DVDRAM GH40N | Fedora 32

Reply 19 of 45, by dale5351

User metadata
Rank Newbie
Rank
Newbie
ADDiCT wrote:

I have 4DOS and 4NT, but don't see how that might help here. It is not a problem with piping or redirection.

Just try it, takes only a few minutes.

I have tried that now -- made no difference.