Discussion:
bash syntax problem piping ssh tar
(too old to reply)
Brian
2007-05-30 12:24:56 UTC
Permalink
Hello

I want to do something like this in the console:

tar cfp - mybackup | ssh ***@host (cd /backups/mybackup; tar xvfp -)

so I want the host to receive the stdout tar output from the client and
untar it, but bash complains about the '(' with:
"syntax error near unexpected token '(' "

Is there a way to do this?

Thanks in advance!


using GNU bash, version 3.1.17(1)
--
thanks, Brian
- reply to newsgroup
Bill Marcum
2007-05-30 15:14:29 UTC
Permalink
On Wed, 30 May 2007 08:24:56 -0400, Brian
Post by Brian
Hello
so I want the host to receive the stdout tar output from the client and
"syntax error near unexpected token '(' "
Is there a way to do this?
Thanks in advance!
Use quotes instead of ().
--
BOFH excuse #43:

boss forgot system password
Loading...