Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-670

Prefer local dns does not work expectedly on OCPv4.12

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Normal Normal
    • None
    • 4.12
    • Networking / DNS
    • None
    • Moderate
    • None
    • SDN Sprint 224
    • 1
    • False
    • Hide

      None

      Show
      None
    • NA

      Description of problem:

      When queried dns hostname from certain pod on the certain node, responded from random coredns pod, not prefer local one. Is it expected result ?
      
      # In OCP v4.8.13 case
      // Ran dig command on the certain node which is running the following test-7cc4488d48-tqc4m pod.
      sh-4.4# while : ; do echo -n "$(date '+%H:%M:%S') :"; dig google.com +short; sleep 1; done
      :
      07:16:33 :172.217.175.238
      07:16:34 :172.217.175.238 <--- Refreshed the upstream result
      07:16:36 :142.250.207.46
      07:16:37 :142.250.207.46
      
      // The dig results is matched with the running node one as you can see the above one.
      $ oc rsh  test-7cc4488d48-tqc4m bash -c 'while : ; do echo -n "$(date '+%H:%M:%S') :"; dig google.com +short; sleep 1; done'
      :
      07:16:35 :172.217.175.238 
      07:16:36 :172.217.175.238 <--- At the same time, the pod dig result is also refreshed.
      07:16:37 :142.250.207.46
      07:16:38 :142.250.207.46
      
      
      But in v4.10 case, in contrast, the dns query result is various and responded randomly regardless local dns results on the node as follows.
      
      # In OCP v4.10.23 case, pod's response from DNS services are not consistent.
      $ oc rsh test-848fcf8ddb-zrcbx  bash -c 'while : ; do echo -n "$(date '+%H:%M:%S') :"; dig google.com +short; sleep 1; done'
      07:23:00 :142.250.199.110
      07:23:01 :142.250.207.46
      07:23:02 :142.250.207.46
      07:23:03 :142.250.199.110
      07:23:04 :142.250.199.110
      07:23:05 :172.217.161.78
      
      # Even though the node which is running the pod keep responding the same IP...
      sh-4.4# while : ; do echo -n "$(date '+%H:%M:%S') :"; dig google.com +short; sleep 1; done
      07:23:00 :172.217.161.78
      07:23:01 :172.217.161.78
      07:23:02 :172.217.161.78
      07:23:03 :172.217.161.78
      07:23:04 :172.217.161.78
      07:23:05 :172.217.161.78
      
      

      Version-Release number of selected component (if applicable):

      v4.10.23 (ROSA)
      SDN: OpenShiftSDN

      How reproducible:

      You can always reproduce this issue using "dig google.com" from both any pod and the node the pod running according to the above "Description" details.

      Steps to Reproduce:

      1. Run any usual pod, and check which node the pod is running on.
      2. Run dig google.com on the pod and the node.
      3. Check the IP is consistent with the running node each other. 

      Actual results:

      The response IPs are not consistent and random IP is responded.

      Expected results:

      The response IP is kind of consistent, and aware of prefer local dns.

      Additional info:

      This issue affects EgressNetworkPolicy dnsName feature.

              mkennell@redhat.com Martin Kennelly
              rhn-support-dapark Daein Park
              Melvin Joseph Melvin Joseph
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: