Hi ,
I m getting an error after executing the script.
My script.
Script is used to find out the date on 8 different machines(mentioned in SERVERNAMES file).
I have added public key to avoid ssh password and ssh without password working fine.
Code:
#!/bin/sh
fn_VMFind()
{
Date=`ssh -t -t -q root@$1 date`
echo $Date
}
while read line
do
fn_VMFind "$line"
done < SERVERNAMES
There are total 8 Server IP addresses mentioned in SERVERNAMES file.
Quote:
SERVERNAMES
10.180.5.231
10.180.5.232
10.180.5.233
10.180.5.234
10.180.5.235
10.180.5.236
10.180.5.237
10.180.5.238
|
output:
Code:
tcgetattr: Inappropriate ioctl for device
Thu Jul 8 13:59:13 IST 2010
It shows Date on Only first server.
What can be the issue?