SUMMARY: reading DOS-diskettes

From: Harald Baumgartner <hmb_at_xray.mpe.mpg.de>
Date: Tue, 13 Apr 1999 09:56:07 +0200

Here the original question:

Hi Manager's
     
i got a DOS-diskette and be able to see the contents:
     
/usr/bin/mtools/mdir a:/
Warning: "//.mcwd" is out of date, contents ignored
 Volume in drive A is FT
 Directory for A:/

199904~1 ABX 1380 3-31-99 3:50p
199904~2 ABX 81184 3-31-99 3:50p
199904~3 ABX 586696 3-31-99 12:23p
ABX_19~1 ABX 4687 3-31-99 3:07p
ABX_19~2 ABX 57556 3-31-99 12:42p
TABLE_~1 332 3-31-99 5:05p
       6 File(s) 724480 bytes free
     
but i'm not able to copy these files (the filenames are much longer as 8 cha-
racters) to this DEC-Unix machine (V4.0B) with mcopy.
Usage: /usr/bin/mtools/mcopy [-tnvm] sourcefile targetfile

/usr/bin/mtools/mcopy a:/199*.ABX *.lis
/usr/bin/mtools/mcopy: No match.

Any idea what i made wrong?

Here are the answers:

Thanks to:

Hans Ranke
Dr. Tom Blinn
Simon Greaves
Oyanarte Portil
georg.tasman

try:
1. /usr/bin/mtools/mcopy 'a:/199*.ABX' . this works


2. Read the mcopy reference page carefully. Bear in mind that the directory on
the floppy is NOT readable by the shell, and all the wildcarded access would
be done by the shell, and you'll see why putting the command you did doesn't
work -- the shell has NO IDEA of the file names on the floppy. As for using
long file names, it doesn't work. The "mtools" have no knowledge of the new
Windows long file names -- they only know about the MS-DOS names, and that's
what you are seeing. I suspect the "TABLE_~1" file is what contains the list
of long name to DOS name mappings that Windows 95 and later uses, but I don't
know for sure because so much of what's in Windows 95 is Microsoft's secret.

If you want to copy the files from the floppy to your local disk, then you've
got to use one copy command per file, and you've got to put the full name of
the input file as it appears on the floppy in the command line, and you may
need to put the file name in quotes (since it's got that tilde character that
DOS puts in the name, and that may cause problems for the shell).

It's much easier to use the mtools commands if you put them in your path; in
that case you don't need to put in the full path name.

In other words, you CAN use mcopy to copy the files, but it's messy, and it
isn't going to support Windows 95 and later long file names.

You might have more success mounting the floppy drive on a current Linux box
and then exporting the floppy to your Digital UNIX system.


3.
The wildcard is not escaped hence is expanded by the shell before
passing to mtools. Use:

        /usr/bin/mtools/mcopy a:/199\*.ABX . this works well:
Copying 199904~1.ABX
Copying 199904~2.ABX
Copying 199904~3.ABX but we copied them from Windows-NT computer, because
                        we need the long filenames


                                Thanks, H. Baumgartner

-- 
Harald Baumgartner Max-Planck-Inst. fuer Extraterrestrische Physik
                   Postf. 1603, D-85740, Garching bei Muenchen, Germany
                   Phone :(Country Code 49) 89 3299-3346 (Fax: -3569)
                   e-mail: hmb_at_mpe.mpg.de, MPE::HMB
		   http://www.xray.mpe.mpg.de/~hmb/
Received on Tue Apr 13 1999 - 07:58:54 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:39 NZDT