I need to get /mysqlsharedetails from all the MySQL servers.I have written a script using a whileread loop, but it's getting the details of only the first server,#!/bin/kshfile=/home/mysqladm/server_list/server_list.txt# while loopwhile IFS= read -r ado        # display line or do something on $line        output=`ssh $a df -h | grep mysqlshare`#echo $a,$outputecho $a ,$output >> /home/mysqladm/server_list/output.txtdone < $fileI have server_list.txt file in which there are two servers like,server_name1,server_name2,it's going to server_name1 and doing df -h and getting out of script.Why is the loop not working?
Script to see /mysqlshare is present in all list servers, doing only first iteration
shell script;ksh