SCSI DAT with Cygnus Software

Manfred Drechsel manfred.drechsel@bns.baynet.de
Sat Jul 26 06:41:00 GMT 1997


Hi Sergey,

I read your answer to Michael Hirmke, regarding usage of 'set strace ...' to
find out the problem with Cygnus tar and SCSI drives under NT.

This is the result in my case ...

...
TAR.EXE 1000) open (/dev/st0, 0x10000)
TAR.EXE 1000) fhandler_base::open (/dev/st0, 0x10000)
TAR.EXE 1000) conv_to_win32_path (/dev/st0)
TAR.EXE 1000) /dev/st0 = normalize_posix_path (/dev/st0)
TAR.EXE 1000) \\.\tape0\ = conv_to_win32_path (/dev/st0)
TAR.EXE 1000) -1 = CreateFileA (\\.\tape0\, 0x80000000, 0x7, 0x241EAA4,
0x3, 0x80, 0)
TAR.EXE 1000) /f/cygnus/cdk/winsup/fhandler.cc:415 seterrno: 87
(ERROR_INVALID_PARAMETER) -> 22
TAR.EXE 1000) 0x0 = fhandler_base::open (/dev/st0, 0x10000)
TAR.EXE 1000) -1 = open (/dev/st0, 0x10000)
TAR.EXE 1000) write (2, 0x241E430, 7)
...

As you see, conv_to_win32_path (path.cc) adds a additional '\'
to \\.\tape0, which of course is invalid. I changed path.cc in a way,
that if 'tape0' is found in the string, the appended '\' is removed.

This then gives following error:

./tar: Read error on /dev/st0: Permission denied
./tar: At beginning of tape, quitting now

And the trace file is:

...
TAR.EXE 1000) open (/dev/st0, 0x10000)
TAR.EXE 1000) fhandler_base::open (/dev/st0, 0x10000)
TAR.EXE 1000) conv_to_win32_path (/dev)
TAR.EXE 1000) /dev = normalize_posix_path (/dev)
TAR.EXE 1000) x:\nt_utl\gnu\dev = conv_to_win32_path (/dev)
TAR.EXE 1000) path.cc:1159 seterrno: 2 (ERROR_FILE_NOT_FOUND) -> 2
TAR.EXE 1000) conv_to_win32_path (/dev/st0)
TAR.EXE 1000) /dev/st0 = normalize_posix_path (/dev/st0)
TAR.EXE 1000) \\.\tape0 = conv_to_win32_path (/dev/st0)
TAR.EXE 1000) 136 = CreateFileA (\\.\tape0, 0x80000000, 0x7, 0x241EA2C,
0x3, 0x80, 0)    <--- OK !!
TAR.EXE 1000) set handle to 136
TAR.EXE 1000) 0x2E80164 = fhandler_base::open (/dev/st0, 0x10000)
TAR.EXE 1000) 3 = open (/dev/st0, 0x10000)
TAR.EXE 1000) 0 = GetFileInformationByHandle (/dev/st0, 136)
TAR.EXE 1000) 0 = fstat (, 0x241EAC4)
TAR.EXE 1000) 0 = fstat (3, 241EAC4)
TAR.EXE 1000) read (3, 0x2E85804, 10240)
TAR.EXE 1000) ReadFile /dev/st0 failed				<-----  FAILED !!
TAR.EXE 1000) -1 = read (3, 0x2E85804, 10240)
...

I did not go deeper into it ...


Manfred Drechsel

BTW: I use BL18 on NT 4.0SP3

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".



More information about the Cygwin mailing list