Is there a tool for Linux that can "persist" IP address during DNS server fail? So domain can be still resolvable on this machine despite of remote DNS server temporary fail.
The scenario is that I have a machine with my web application deployed on it. The application has to connect to remote resource. This resource is not under my control - it is third party Web Service provided by other company, but it is under my client's domain name. Client's DNS servers fail from time to time, so my application cannot resolve domain name, but this third party WS is still available (client's DNS fail is irrelevant to it), so I could reach it by IP and do my job.
So I am looking for tool (DNS cache?) that will resolve domain names through DNS as long as DNS server is up and will return last obtained value when DNS server is down.
Reducing DNS requests count is not what I am interested in this scenario, so "classic" DNS cache is not a solution here (I think).
Scenario with local DNS cache that will not work for me:
1. remote DNS is working well
2. local DNS cache is caching the response from remote DNS
3. before TTL of response expires, remote DNS collapses
4. until TTL of response expires, cache provides cached response; so far, so good
5. TTL of response expires, cache flushes entry and cannot obtain new response, because remote DNS is still down; this is not good