Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copy "portmap" to /opt/cni/bin for Weave #9286

Merged
merged 1 commit into from
Jun 8, 2020

Conversation

hakman
Copy link
Member

@hakman hakman commented Jun 6, 2020

Weave requires portmap that seems to be missing at the moment:
https://www.weave.works/docs/net/latest/kubernetes/kube-addon/#-installation

e2e tests are failing because of the missing portmap plugin:
https://testgrid.k8s.io/kops-network-plugins#kops-aws-cni-weave

E0608 09:35:30.294544    5002 kubelet.go:2187] Container runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:docker: network plugin is not ready: cni config uninitialized
I0608 09:35:33.143148    5002 kubelet.go:1952] SyncLoop (PLEG): "weave-net-6v74s_kube-system(14526285-9260-43e3-8c5e-62eb340b2dc1)", event: &pleg.PodLifecycleEvent{ID:"14526285-9260-43e3-8c5e-62eb340b2dc1", Type:"ContainerStarted", Data:"6cea0ffccafd5578fc62e565b78258d4d10bc6fc11be27b5e1990fbc0b40cf2e"}
W0608 09:35:34.281513    5002 cni.go:202] Error validating CNI config list {
    "cniVersion": "0.3.0",
    "name": "weave",
    "plugins": [
        {
            "name": "weave",
            "type": "weave-net",
            "hairpinMode": true
        },
        {
            "type": "portmap",
            "capabilities": {"portMappings": true},
            "snat": true
        }
    ]
}
: [failed to find plugin "portmap" in path [/opt/cni/bin/]]
W0608 09:35:34.282448    5002 cni.go:237] Unable to update cni config: no valid networks found in /etc/cni/net.d/

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. area/nodeup labels Jun 6, 2020
@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Jun 6, 2020
@olemarkus
Copy link
Member

Hm. I thought the daemonset deployed this. Thanks for fixing.

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 6, 2020
@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

Thanks @olemarkus. I checked the weave code and it's not the case.
Btw, I think there's something wrong with amazonvpc also and may be related.

@olemarkus
Copy link
Member

/assign @mikesplain

@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

e2e test failure is related to kubernetes/test-infra#17864

return nil
}

b.AddCNIBinAssets(c, []string{"portmap"})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It may be that you have to add "loopback" too. This one isn't used by the CNI, but used by kubernetes internally.
If that is the case you should see something like

  Warning  FailedCreatePodSandBox  7m24s (x4 over 7m27s)    kubelet, ip-10-140-60-250.eu-central-1.compute.internal  (combined from similar events): Failed to create pod sandbox: rpc error: code = Unknown desc = failed to set up sandbox container "8e7c8b6aaf6ac0c5a84b8326a724f69b6f21e9d1c5b055e42081b88d70816dd7" network for pod "kube-dns-autoscaler-7647db5967-lwdjw": networkPlugin cni failed to set up pod "kube-dns-autoscaler-7647db5967-lwdjw_kube-system" network: failed to find plugin "loopback" in path [/opt/cni/bin/]

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't notice this while testing, so let's see how tests go in TestGrid.

@mikesplain
Copy link
Contributor

Thanks!

/lgtm
/approve

@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

Thanks guys :)

@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

/retest

@mikesplain
Copy link
Contributor

/retest

3 similar comments
@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

/retest

@hakman
Copy link
Member Author

hakman commented Jun 6, 2020

/retest

@johngmyers
Copy link
Member

/retest

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 8, 2020
@hakman
Copy link
Member Author

hakman commented Jun 8, 2020

@mikesplain I think somehow the bot did not see the approval.

@mikesplain
Copy link
Contributor

Ahh yeah, it removed it since the branch was pushed again.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 8, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hakman, mikesplain

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 8, 2020
@k8s-ci-robot k8s-ci-robot merged commit 11259b5 into kubernetes:master Jun 8, 2020
@k8s-ci-robot k8s-ci-robot added this to the v1.19 milestone Jun 8, 2020
@hakman hakman deleted the weave-portmap branch July 1, 2020 03:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/nodeup cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants