Project

General

Profile

Actions

Bug #34462

closed

Shorten DNS timeout for primary NIC detection

Added by Lukas Zapletal almost 3 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Category:
Facts
Target version:
-
Difficulty:
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

In facts parsing code we have a very old code bit that performs DNS reverse query for each IP address until it finds a PTR record matching the hostname of the host that sent facts. This works for all fact types which do not override the method in its implementation (e.g. Ansible, possibly others).

During testing today my fact queries were delayed to 75 seconds which turns out to be my OS default value. That is too much, hosts with many IP addresses can cause huge delays if DNS does not reply fast enough. This can easily overload the application server with unfinished requests.

I am proposing to shorten the DNS timeout to something sane like 250ms. If it does not return quickly, then the only drawback is that primary interface might not be detected correctly for unmanaged hosts. Not a big deal.

Actions #1

Updated by The Foreman Bot almost 3 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/9108 added
Actions #2

Updated by The Foreman Bot over 2 years ago

  • Fixed in Releases 3.3.0 added
Actions #3

Updated by Lukas Zapletal over 2 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF