help-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-tar] GNU tar and/on Windows server


From: Jakob Bohm
Subject: Re: [Help-tar] GNU tar and/on Windows server
Date: Tue, 21 Jan 2014 16:51:22 +0100
User-agent: Mozilla/5.0 (Windows NT 5.2; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0

On 1/12/2014 8:27 AM, Mike Pepe wrote:
Greetings- I'm not sure if I'm going to find anyone who has tried this, but
I hope someone may have a pointer as to what may be going on.

I'm trying to back up data to a tape drive attached to a Windows 2012
server. When I attempt to do this with the version of tar supplied in
unxutils, I get this error:

C:\temp>tar --version
tar (GNU tar) 1.12

Copyright (C) 1988, 92, 93, 94, 95, 96, 97 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Written by John Gilmore and Jay Fenlason.

C:\temp>tar cvf \\.\Tape0 .
tar: Cannot open \\.\Tape0: Invalid argument
tar: Error is not recoverable: exiting now
Hmm, I haven't tried this in a long time, are you sure the \\.\Tape0 Win32
device name is
the right one?

The other likely possibility would be some aspect of how the UnxUtils
porters pass the file name to the Win32 system level "open()", aka
"CreateFile()" .


For instance, if they try to prefix "C:" or do other incorrect reparsing,
or if they pass open flags inconsistent with tape drives.


As an experiment, the tar in Cygwin does actually work:
The Cygwin translation layer obviously does not involve passing the Win32
device name though the upper layers of tar and libc, and may do
unspecified things inside the modified newlibc in order to make tape opens
work, given that Cygwin obviously has special case tape open code which
recognizes the "/dev/st0" file name and maps it to either \\.\Tape0 or
something similar.


$ tar --version
tar (GNU tar) 1.26
Packaged by Cygwin (1.26-1)
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by John Gilmore and Jay Fenlason.

address@hidden ~
$ tar cvf /dev/st0 /cygdrive/c/temp
<snip>


Enjoy

Jakob
-- 
Jakob Bohm, CIO, Partner, WiseMo A/S.  http://www.wisemo.com
Transformervej 29, 2730 Herlev, Denmark.  Direct +45 31 13 16 10
This public discussion message is non-binding and may contain errors.
WiseMo - Remote Service Management for PCs, Phones and Embedded

reply via email to

[Prev in Thread] Current Thread [Next in Thread]