On Wed, Jan 07, 2015 at 08:28:01AM -0600, address@hidden wrote:
> Would y'all explain in simple terms what is going wrong here
>
> while read l; do echo "checking ${l}"; ssh ${l} ls; done <list_of_servers
>
> After the first server the loop terminateshttp://mywiki.wooledge.org/BashFAQ/089
Brief explanation: ssh and read are both reading from the same stdin
stream. ssh is greedy and grabs all the data. The wiki page shows
some workarounds.