Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

reading line in ssh, pls help ...

Status
Not open for further replies.

h3nd

Programmer
Jul 1, 2006
147
AU
Hi guys

Here's my code :
Code:
while read line
do
        echo "$line\tPROD\t$number"
done < list1

while read line
do
        ssh ypdrp01 echo "$line\tDRP\t$number"
done < list1

The first loop is fine, but the second loop didnt work fine, It just read the first line. So could you guys help me why ?

Thx guys,
 
ssh ypdrp01 echo "$line\tDRP\t$number" [!]</dev/null[/!]

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
If PHV's answer doesn't work try
Code:
ssh [b]-n[/b] ypdrp01 echo "$line\tDRP\t$number"
As ever run the script with ksh -xv to help debugging

Ceci n'est pas une signature
Columb Healy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top