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

Bandwidth doesn't work with calico 3.2.4 #242

Closed
CallMeFoxie opened this issue Dec 6, 2018 · 3 comments
Closed

Bandwidth doesn't work with calico 3.2.4 #242

CallMeFoxie opened this issue Dec 6, 2018 · 3 comments

Comments

@CallMeFoxie
Copy link
Contributor

CallMeFoxie commented Dec 6, 2018

Hi,
I've been testing the bandwidth plugin and it seems to have a problem with calico 3.2.4 with this config:

{
  "cniVersion": "0.3.0",
  "plugins": [
  {
      "etcd_endpoints": "https://etcd_redacted_servers",
      "etcd_key_file": "/www/adm/calico/cert/etcd-key.pem",
      "kubernetes": {
        "kubeconfig": "/www/adm/kubernetes/conf/kubeconfig.kubelet.yaml"
      },
      "log_level": "info",
      "ipam": {
        "type": "host-local",
        "subnet": "usePodCidr"
      },
      "etcd_cert_file": "/www/adm/calico/cert/etcd-cert.pem",
      "policy": {
        "type": "k8s"
      },
      "type": "calico",
      "etcd_ca_cert_file": "/www/adm/calico/cert/etcd-ca.pem"
    },
    {
      "snat": true,
      "capabilities": {
        "portMappings": true
      },
      "type": "portmap"
    },
    {
      "type": "bandwidth",
      "capabilities": {"bandwidth": true}
    }
  ],
  "name": "mynet"
}

I've tracked it down to this line:

https://github.com/containernetworking/plugins/blob/master/plugins/meta/bandwidth/main.go#L145

where the iface.Sandbox = eth0 in this case and never matches any interface.

Is it problem on calico side, my configuration side or bandwidth plugin side? When I comment out that check it works fine.

@squeed
Copy link
Member

squeed commented Dec 6, 2018

Nice find!

It looks like a Calico bug. Specifically, the spec says that plugins should not set "iface.Sandbox" if the interface is in the "root" namespace. @matthewdupre - any thoughts?

@CallMeFoxie
Copy link
Contributor Author

Oh it seems to have been fixed in the 3.3 branch :)

projectcalico/cni-plugin#607

@dcbw
Copy link
Member

dcbw commented Jan 9, 2019

thanks for the update, closing.

@dcbw dcbw closed this as completed Jan 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants