I've checked the Google Webmaster Tools this morning, and some of my main pages says "IP in excluded range" for errors for URLs in Sitemaps. What could this possible mean?
This issue is related to your hosting company, not your web pages. You need to contact them and have them review your hosting account or dedicated server DNS setup.
I am on a dedicated server, I have set up private dns server correctly according to tutorials I found on the web. However I am suspecting my banning script is backfiring. Because if the server detects any form of flooding, it will ban it and re-route it to localhost or 127.0.0.1 My theory was, if a hacker was ddosing my site, it will be ddosing its own server because they are re-routed to localhost. I guess, I need to exclude google ips...
That would not prevent a DDoS attack, the whole concept of a DDoS attack is it comes from 1,000s to 100,000s of different computers (IPs). Plus, most would attack your name server or dns server directly to give a real downtime effect.
But, my dns server is on my server, so it will detect it using iptables. It doesn't matter how many different ips it is from, it will detect most, and apply the rule.