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

[release-4.20] Terminal disconnected when pod YAML changes (without pod restart)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Undefined Undefined
    • 4.20.z
    • 4.19.z
    • Management Console
    • None
    • None
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • None
    • None
    • Done
    • Bug Fix
    • Hide
      Before this update, when opening a terminal to a running pod, the session disconnected whenever the annotations of the pod changed. With this release, the terminal session no longer disconnects when the annotations are changed. (link:https://issues.redhat.com/browse/OCPBUGS-65900[OCPBUGS-65900])
      Show
      Before this update, when opening a terminal to a running pod, the session disconnected whenever the annotations of the pod changed. With this release, the terminal session no longer disconnects when the annotations are changed. (link: https://issues.redhat.com/browse/OCPBUGS-65900 [ OCPBUGS-65900 ])
    • None
    • None
    • None
    • None

      This is a clone of issue OCPBUGS-65776. The following is the description of the original issue:

      When opening a terminal to a running pod the session is frequently disconnected whenever the pod's yaml is changed although the pod itself is not restarted (ie. annotation changes). In the customer's example this is a postgres pod regularly updating the pods's annotation see:

      $ while true; do oc get pod -n test sc-fzpfz-ba97-test-c-h26d-0 -o jsonpath='{.metadata.annotations.status}' && echo; sleep 10; done {"conn_url":"postgres://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:5432/postgres","api_url":"https://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:8008/patroni","state":"running","role":"primary","version":"4.1.0","xlog_location":17176463426016,"timeline":136} {"conn_url":"postgres://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:5432/postgres","api_url":"https://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:8008/patroni","state":"running","role":"primary","version":"4.1.0","xlog_location":17176463429816,"timeline":136} {"conn_url":"postgres://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:5432/postgres","api_url":"https://sc-fzpfz-ba97-test-c-h26d-0.sc-fzpfz-ba97-test-pods:8008/patroni","state":"running","role":"primary","version":"4.1.0","xlog_location":17176480186872,"timeline":136}

       

      But the issue can easily be reproduced.

       

      To reproduce the issue:

      1. Create a sample namespace

      2. Deploy a sample app (i.e. nginx sample)

      3. Open a terminal to the running pod. Type something like "time" to see terminal is active

      4. Run 

      oc patch pod my-pod --patch '{"metadata":{"annotations":{"foo":"bar"}}}'

      5. Find the terminal is disconnected and connection reestablished (you will no longer see the results from running "time")

       

      The issue is not observed in 4.19.13 but is seen in 4.19.16 and onwards (verified in 4.19.18 from fast channel it's still present). So some change in the console has introduced this behaviour.

              rh-ee-jaclee Jackson Lee
              rhn-support-afaulhab Anne Faulhaber
              None
              None
              Yanping Zhang Yanping Zhang
              None
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: