scp to pipe

From: hlaguy (hlaguy_at_excite.com)
Date: 09/11/04

  • Next message: Albert Lunde: "Re: REQ: SSH behaviour dependent from the connecting client"
    To: secureshell@securityfocus.com
    Date: Sat, 11 Sep 2004 05:49:56 -0400 (EDT)
    
    

    How can scp write to a pipe that tar could then process?

    On i386 Gentoo Linux, using bash, the following works

    cat myfile.tar.gz | tar -xf

    however, this does not work

    scp myuser@mycomp:~/myfile.tar.gz | tar -xz

    gzip: stdin: unexpected end of file
    tar: Child returned status 1
    tar: Error exit delayed from previous errors

    nor does this

    tar -xz < scp myuser@mycomp:~/myfile.tar.gz

    I can't think of a way to tell scp to write to pipe instead of a named file. Any suggestions are welcome.

    _______________________________________________
    Join Excite! - http://www.excite.com
    The most personalized portal on the Web!


  • Next message: Albert Lunde: "Re: REQ: SSH behaviour dependent from the connecting client"

    Relevant Pages

    • Re: scping 250,000 files
      ... I would prefer to use scp. ... The general solution is to use find, pipe though tar, pipe to ssh ... on the remote machine, change dir and use tar to unpack on the ...
      (comp.unix.shell)
    • Re: scp to pipe
      ... But you dont get anything else from stderr either. ... > How can scp write to a pipe that tar could then process? ... > I can't think of a way to tell scp to write to pipe instead of a named file. ...
      (SSH)
    • Re: scp to pipe
      ... There is a reason why the usage of tar and scp. ... In reference of below, that should work fine or simply choose for a scp ... Could somebody explain me the explicit use of the pipe, ...
      (SSH)
    • Re: scp to pipe
      ... > How can scp write to a pipe that tar could then process? ... It's not all clear fot me, but i think you may want this: ...
      (SSH)
    • Re: Extending Expiration Date of an Already-Expired GPG Key
      ... When I return home from my trip I then tar up the .thunderbird directory ... on the laptop and scp it back to the desktop. ...
      (Fedora)