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

Terminal disconnected when pod YAML changes (without pod restart)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • 4.19.z
    • Management Console
    • None
    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • None
    • None
    • In Progress
    • Bug Fix
    • Hide
      Previously, when opening a terminal to a running pod, the session is disconnected whenever the annotations of the pod change. In this update, the terminal session no longer disconnects when this metadata is changed.
      Show
      Previously, when opening a terminal to a running pod, the session is disconnected whenever the annotations of the pod change. In this update, the terminal session no longer disconnects when this metadata is changed.
    • None
    • None
    • None
    • None

      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:
              5 Start watching this issue

                Created:
                Updated: