Reputation
Top tag
Next privilege 50 Rep.
Comment everywhere
Badges
3
Newest
 Supporter
Impact
~1k people reached

  • 0 posts edited
  • 0 helpful flags
  • 2 votes cast
Feb
14
awarded  Supporter
Feb
14
accepted Scripted command line with redirection fails
Feb
14
comment Scripted command line with redirection fails
eval $UZPCMD worked like a charm. Thanks, Daniel!
Feb
14
comment Gunzip redirection: “No such file or directory”
Apart from accepting an answer, is there anything I need to do to close out the question?
Feb
14
asked Scripted command line with redirection fails
Feb
14
awarded  Scholar
Feb
14
accepted Gunzip redirection: “No such file or directory”
Feb
14
comment Gunzip redirection: “No such file or directory”
That works from the command line, but fails as script. The following command lines: UZPCMD="gunzip -c "$TMPDIR"/in/"$FILEONLY" >> "$TMPDIR"/outfile.000" echo $TMPDIR echo $FILEONLY echo $UZPCMD produce the following output - the gunzip command line looks as it should: /disk1/hadoop/gunzip_tmp part-00006.gz gunzip -c /disk1/hadoop/gunzip_tmp/in/part-00006.gz >> /disk1/hadoop/gunzip_tmp/outfile.000 However, issuing the command line from the script: $UZPCMD sends line after line of the unzipped file to stdout (as if redirect were ignored).
Feb
14
awarded  Student
Feb
14
asked Gunzip redirection: “No such file or directory”