Hi Admins,
I was trying to list the failed logins as part of my daily checklist.
Here is my script
for i in `who -s /etc/security/failedlogins|tail -100|grep "$dt"|awk '{print $1" "$6}'`
do
a=`echo $i|wc -l`
if [ $a -gt 0 ]
then
echo $i
else
echo "There are no failed logins"
fi
done
but m getting output in multiple lines.If there are two entries output will be scattered in multiple lines.Please tell me how to print the output in 2 lines(for 2 entries for example). I have used \n with echo $i.. but no use..
Regards
new aix