Skip to content

deployment failed: caused by a config change #10765

Closed

Description

@liggitt

https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin_conformance/5805/consoleFull#103359503156cbb9a5e4b02b88ae8c2f77

[Fail] deploymentconfigs when run iteratively [It] should only deploy the last deployment [Conformance] 
/data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:120

[Fail] deploymentconfigs when run iteratively [It] should immediately start a new deployment [Conformance] 
/data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:167
    should only deploy the last deployment [Conformance]
    /data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:131

    Expected error:
        <*errors.errorString | 0xc8209a87b0>: {
            s: "deployment failed: caused by a config change",
        }
        deployment failed: caused by a config change
    not to have occurred
    /data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:120
    should immediately start a new deployment [Conformance] [It]
    /data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:190

    Expected error:
        <*errors.errorString | 0xc8200ce130>: {
            s: "timed out waiting for the condition",
        }
        timed out waiting for the condition
    not to have occurred
    /data/src/github.com/openshift/origin/test/extended/deployments/deployments.go:167

Activity

  1. added
    kind/test-flake
    on Sep 1, 2016
  2. self-assigned this
    on Sep 1, 2016
  3. 0xmichalis commented on Sep 1, 2016

    @0xmichalis
    Contributor

    Both of the tests run in the same group (accident?)

    The second failure is interesting. The first deployment is marked as cancelled, the deployer pod has a deletionTimestamp, but it continues Running. The deployment controller will never mark the deployment as Failed and the deploymentconfig controller will never create the second deployment

    Sep  1 08:49:47.209: INFO: Running 'oc create --namespace=extended-test-cli-deployment-1ahw3-8h8q2 --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-8h8q2-user.kubeconfig -f /data/src/github.com/openshift/origin/test/extended/testdata/deployment-simple.yaml -o name'
    Sep  1 08:49:47.445: INFO: Running 'oc set env --namespace=extended-test-cli-deployment-1ahw3-8h8q2 --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-8h8q2-user.kubeconfig deploymentconfig/deployment-simple TRY=ONCE'
    STEP: by checking that the deployment config has the correct version
    STEP: by checking that the second deployment exists
    
    kind: ReplicationController
    metadata:
      annotations:
        kubectl.kubernetes.io/desired-replicas: "2"
        openshift.io/deployer-pod.name: deployment-simple-1-deploy
        openshift.io/deployment-config.latest-version: "1"
        openshift.io/deployment-config.name: deployment-simple
        openshift.io/deployment.cancelled: "true"
        openshift.io/deployment.phase: Running
        openshift.io/deployment.replicas: "0"
        openshift.io/deployment.status-reason: newer deployment was found running
    
    kind: Pod
    metadata:
      annotations:
        openshift.io/deployment.name: deployment-simple-1
        openshift.io/scc: restricted
      creationTimestamp: 2016-09-01T12:49:47Z
      deletionGracePeriodSeconds: 10
      deletionTimestamp: 2016-09-01T12:49:57Z
    ...
      phase: Running
      podIP: 172.17.0.7
      startTime: 2016-09-01T12:49:47Z
    
  4. 0xmichalis commented on Sep 3, 2016

    @0xmichalis
    Contributor

    First test seems to fail because we wait for the deployment to be running when it is already failed

    Sep  1 08:49:28.255: INFO: 10: waiting for current deployment to start running
    Sep  1 08:49:39.958: INFO: Running 'oc get --namespace=extended-test-cli-deployment-1ahw3-1dddx --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-1dddx-user.kubeconfig dc/deployment-simple -o yaml'
    
  5. 0xmichalis commented on Sep 3, 2016

    @0xmichalis
    Contributor

    Also interesting for the first test is that the deployer container never run

      conditions:
      - lastProbeTime: null
        lastTransitionTime: 2016-09-01T12:49:29Z
        status: "True"
        type: Initialized
      - lastProbeTime: null
        lastTransitionTime: 2016-09-01T12:49:29Z
        message: 'containers with unready status: [deployment]'
        reason: ContainersNotReady
        status: "False"
        type: Ready
      - lastProbeTime: null
        lastTransitionTime: 2016-09-01T12:49:29Z
        status: "True"
        type: PodScheduled
      containerStatuses:
      - containerID: docker://00181a5da795097f23fadc33c1a7521a4fce7d2660733a784e7224b1c0fc5117
        image: openshift/origin-deployer:4afe8c6
        imageID: docker://sha256:2542190dd5300676d4a23ca10b677af9c930b2d5a814733d2fa7ed6f1756fb32
        lastState: {}
        name: deployment
        ready: false
        restartCount: 0
        state:
          terminated:
            containerID: docker://00181a5da795097f23fadc33c1a7521a4fce7d2660733a784e7224b1c0fc5117
            exitCode: 128
            finishedAt: 2016-09-01T12:49:32Z
            reason: ContainerCannotRun
            startedAt: 2016-09-01T12:49:32Z
    
  6. 0xmichalis commented on Sep 3, 2016

    @0xmichalis
    Contributor

    Second test:

    Sep  1 08:49:47.209: INFO: Running 'oc create --namespace=extended-test-cli-deployment-1ahw3-8h8q2 --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-8h8q2-user.kubeconfig -f /data/src/github.com/openshift/origin/test/extended/testdata/deployment-simple.yaml -o name'
    Sep  1 08:49:47.445: INFO: Running 'oc set env --namespace=extended-test-cli-deployment-1ahw3-8h8q2 --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-8h8q2-user.kubeconfig deploymentconfig/deployment-simple TRY=ONCE'
    STEP: by checking that the deployment config has the correct version
    STEP: by checking that the second deployment exists
    Sep  1 08:50:18.254: INFO: Running 'oc get --namespace=extended-test-cli-deployment-1ahw3-8h8q2 --config=/tmp/openshift/extended-test-cli-deployment-1ahw3-8h8q2-user.kubeconfig dc/deployment-simple -o yaml'
    

    The deployment config is updated at 08:49:47 with oc set env but the deletionTimestamp is set on the deployer pod at 2016-09-01T12:49:57Z, ie. 10 seconds later. It would be useful to know what time did the deploymentconfig controller cancel the deployment. Currently, we save "true" as a value for the cancelled annotation. We should switch it to a timestamp.

  7. 0xmichalis commented on Sep 3, 2016

    @0xmichalis
    Contributor

    Another interesting observation: deletionGracePeriod of the deployer is currently set to 10s. The pod was marked for deletion at 12:49:57 and at 08:50:18 (21 seconds later) when the test failed the pod was still running.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

component/appskind/test-flakepriority/P2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions