Edit dns records using sed
February 5th, 2009
You can easily replace an existing IP with and new IP in a dns record using sed. Here is the way you do it.
sed -e ’s#xx.xx.xx.xx#yy.yy.yy.yy#g’ domain.com > new.domain.com
where xx.xx.xx.xx is the existing IP and yy.yy.yy.yy is the new IP