look=$( for i in $(cat list ); do nslookup $i | grep Address | grep -v -e "53" -e "Server" | cut -d ':' -f2; done; )
for abc in $look
if $abc = $var1 ; then
echo "$abc - Ip is correct - "
echo "$abc - IP is not correct - "
I want the output like following.
18.104.22.168 - IP is correct example.com
Currect script only print output
22.214.171.124 - IP is correct -
Can any one help me to add domainname with the output.
NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
This topic has been locked.
1 reply Latest Post - 2009-12-11T16:25:05Z by pk.habi
Pinned topic dns records lookup
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2009-12-11T16:25:05Z at 2009-12-11T16:25:05Z by pk.habi