0

I have a Postgres service in Centos 7 and it works normally.

Each time when the internet service (by an IPS) is down, the responses are slow, other times the DNS is reset by an electrical trouble, forcing to set 192.168.2.1, and the responses are slow too.

Trying to solve the trouble, I change the DNS (192.168.2.1 - this is my lan dns) to [8.8.8.8] (google's one) and the responses comes back to work normally.

Anyone can tell why this happens? Have I configured something wrong in the installation?

Note: this happens in 15 database servers (one per store).

migrated from stackoverflow.com Dec 20 '18 at 19:23

This question came from our site for professional and enthusiast programmers.

  • Have you tried with tracert? – McNets Dec 20 '18 at 20:05
  • Do you have log_hostname turned on? That does a reverse lookup of the host/IP when a connection is established. But it will not affect the performance of a query, only the time it takes to establish a connection – a_horse_with_no_name Dec 21 '18 at 6:55
0

something is doing dns lookups on your connections, check your logging settings are not logging domain names, and ensure that pg_hba.conf contains no host names (only ip addresses)

perhaps use wireshark or tshark to check for DNS traffic on the database server and see what the lookups are.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy