Technology Blog
A technology blog focusing on areas such as Linux, open source tools and scripting
Monday, 9 September 2013
ssh in a loop
Using ssh in a loop will break the loop to fix this use the -n flag, i.e:-
while read server
do
echo $server
ssh -n $server "ls -l /etc/rc.modules"
echo
done < servers
Newer Post
Older Post
Home