[ale] Syntax problem

Geoffrey esoteric at 3times25.net
Wed Aug 24 15:26:57 EDT 2005


Scott Warfield wrote:
> you need the quotes to pass everything as an argument to ssh to be
> executed by the remote server.  in this case, ps ax runs remotely piping
> the output locally to grep resulting in an attempt to kill a pid that
> may not exist at best... at worst, well, you can guess ;)
> 
> answer to this.... escape $.  "\$1"
> 
> ssh machine "ps ax|grep namd|grep -v grep| awk '{print(\$1)}'|xargs
> kill"

Oops, that's correct.  Again though you can rid yourself of the grep 
commands and do all that in awk.

-- 
Until later, Geoffrey



More information about the Ale mailing list