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

devVM: set IPv6 podIP for hostNetwork pods #23503

Closed
2 tasks done
julianwiedmann opened this issue Feb 1, 2023 · 1 comment · Fixed by #23543
Closed
2 tasks done

devVM: set IPv6 podIP for hostNetwork pods #23503

julianwiedmann opened this issue Feb 1, 2023 · 1 comment · Fixed by #23543
Assignees
Labels
feature/ipv6 Relates to IPv6 protocol support kind/bug This is a bug in the Cilium logic. sig/contributing Impacts contribution workflow, guidelines, and tools.

Comments

@julianwiedmann
Copy link
Member

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

When deploying a pod with hostNetwork: true on a dual-stack devVM, the pod status doesn't show an IPv6 address. Expectation is that it shows the node's IPv4 and IPv6 address.

Per https://kubernetes.io/docs/concepts/services-networking/dual-stack/#configure-ipv4-ipv6-dual-stack, this might just be a missing --node-ip parameter for kubelet when setting up the devVM. Probably best to also audit if we set up all the other parameters properly.

Cilium Version

Kernel Version

Kubernetes Version

Sysdump

Relevant log output

kubectl get pod testds-gdpl6
...
        "hostIP": "192.168.60.12",
        "phase": "Running",
        "podIP": "192.168.60.12",
        "podIPs": [
            {
                "ip": "192.168.60.12"
            }
        ],


with a trivial manifest:

apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: testds
spec:
  selector:
    matchLabels:
      zgroup: nodeport-backend-hostns
  template:
    metadata:
      labels:
        zgroup: nodeport-backend-hostns
    spec:
      hostNetwork: true
      nodeSelector:
        kubernetes.io/hostname: k8s1
      containers:
      - name: web
        image: quay.io/cilium/echoserver:1.10.1
        imagePullPolicy: IfNotPresent
        ports:
        - containerPort: 80
        readinessProbe:
          httpGet:
            path: /
            port: 80

Anything else?

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@julianwiedmann julianwiedmann added kind/bug This is a bug in the Cilium logic. needs/triage This issue requires triaging to establish severity and next steps. kind/community-report This was reported by a user in the Cilium community, eg via Slack. area/CI-improvement Topic or proposal to improve the Continuous Integration workflow labels Feb 1, 2023
@jschwinger233
Copy link
Member

this might just be a missing --node-ip parameter for kubelet when setting up the devVM

This is exactly the root cause of the issue. After fixing the kubelet flag, the Node object and Pod object show the ipv6 in their addresses.

Then I'll audit other flags and open a PR to fix it.

Thank you @julianwiedmann

@pchaigno pchaigno added sig/contributing Impacts contribution workflow, guidelines, and tools. and removed kind/community-report This was reported by a user in the Cilium community, eg via Slack. needs/triage This issue requires triaging to establish severity and next steps. area/CI-improvement Topic or proposal to improve the Continuous Integration workflow labels Feb 5, 2023
@squeed squeed added the feature/ipv6 Relates to IPv6 protocol support label Feb 9, 2023
jschwinger233 added a commit to jschwinger233/cilium that referenced this issue Feb 22, 2023
The development setup using the provided Vagrantfile will give a
dual-stack Kubernetes cluster in the dev VM, but a hostNetwork pod
deployed on it cannot show an IPv6 address.

This is because the kubelet is deployed using the incomplete `--node-ip`
parameter: to enable dual-stack mode, we must pass both IPv6 address and
IPv4 address via `--node-ip` to kubelet.

This commit completes the `--node-ip` parameter and fixes the issue.

Fixes: cilium#23503

Signed-off-by: Zhichuan Liang <gray.liang@isovalent.com>
pchaigno pushed a commit that referenced this issue Feb 22, 2023
The development setup using the provided Vagrantfile will give a
dual-stack Kubernetes cluster in the dev VM, but a hostNetwork pod
deployed on it cannot show an IPv6 address.

This is because the kubelet is deployed using the incomplete `--node-ip`
parameter: to enable dual-stack mode, we must pass both IPv6 address and
IPv4 address via `--node-ip` to kubelet.

This commit completes the `--node-ip` parameter and fixes the issue.

Fixes: #23503

Signed-off-by: Zhichuan Liang <gray.liang@isovalent.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature/ipv6 Relates to IPv6 protocol support kind/bug This is a bug in the Cilium logic. sig/contributing Impacts contribution workflow, guidelines, and tools.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants