#110 Cannot specify drive letter with --file option

Tar
open
GnuWin
Binaries (396)
5
2012-07-26
2003-11-19
No

When specifying a drive letter in the argument for the
--file option results in an error:
Example:

tar -c -v --file=C:\TEMP\foo.tar bar.txt
tar: Cannot open C:\TEMP\foo.tar: Function not implemented

Working:
tar -c -v --file=\TEMP\foo.tar bar.txt

Discussion

  • GnuWin

    GnuWin - 2003-11-23

    Logged In: YES
    user_id=217802

    Does it work when you use forward slashes in filenames?

     
  • Joachim Schlosser

    Logged In: YES
    user_id=448088

    No. I tested every combination. As long as no drive letter
    appears, it works, regardless whether forward or backslashes
    are used. But with a drive letter it fails in any case.

     
  • GnuWin

    GnuWin - 2003-11-23

    Logged In: YES
    user_id=217802

    When you give the additional option --force-local, it works.
    Still, this a bug, and will be looked into when the next revision
    of tar will be done.

     
  • Schlief

    Schlief - 2007-06-11

    Logged In: YES
    user_id=1814717
    Originator: NO

    Do we have a fix for this.? I am seeing this problem and the --force-local parameter has no effect.
    In the context of scheduled tasks, I have to provide full paths, including drive letters. I can't
    count on the data all being on the same drive.

    Not working
    tar -xf c:\working\file\testfile.tar --directory=d:\output\file\rad3C717.tmp --force-local

    Working (when on the drive letter already)
    tar -xf \working\file\testfile.tar --directory=\working\file\rad3C717.tmp

    Not working (same, but on the C: Drive)
    tar -xf \working\file\testfile.tar --directory=\working\file\rad3C717.tmp

    pst...many times the source (-f) is on one drive, and the destination (--directory) is on another. Also, / are required instead of \ in the path.

    Note: version 1.13

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks