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

Post OIDC Key rotation, Whereabouts start failing #401

Open
pukubee opened this issue Jan 2, 2024 · 0 comments
Open

Post OIDC Key rotation, Whereabouts start failing #401

pukubee opened this issue Jan 2, 2024 · 0 comments

Comments

@pukubee
Copy link

pukubee commented Jan 2, 2024

Describe the bug
We use OIDC enabled K8s cluster, we rotate OIDC issuer key after few months. Post rotation of the key whereabouts cannot allocate IP for newly created pods.

whereabouts.log

2024-01-02T09:06:16Z [debug] Used defaults from parsed flat file config @ /etc/cni/net.d/whereabouts.d/whereabouts.conf
2024-01-02T09:06:16Z [debug] ADD - IPAM configuration successfully read: {Name:test-sriov Type:whereabouts xxx Routes:[] GatewayStr: LeaderLeaseDuration:1500 LeaderRenewDeadline:1000 LeaderRetryPeriod:500 LogFile:/var/log/whereabouts.log LogLevel:info ReconcilerCronExpression:30 4 * * * OverlappingRanges:true SleepForRace:0 Gateway: Kubernetes:{KubeConfigPath:/etc/cni/net.d/whereabouts.d/whereabouts.kubeconfig K8sAPIRoot:} ConfigurationPath: PodName:test-pod PodNamespace:default NetworkName:}
2024-01-02T09:06:16Z [debug] Beginning IPAM for ContainerID: 21c1209c11d5075e50ae42216e5cc633c6f9d75524eac31f883b28f81f710f21
2024-01-02T09:06:16Z [debug] Started leader election
2024-01-02T09:08:16Z [debug] OnStoppedLeading() called
2024-01-02T09:08:16Z [debug] Finished leader election
2024-01-02T09:08:16Z [debug] IPManagement: [], time limit exceeded while waiting to become leader
2024-01-02T09:08:16Z [error] Error at storage engine: time limit exceeded while waiting to become leader

Restarting whereabouts pods help mitigate this problem.

Expected behavior
A clear and concise description of what you expected to happen.
Looking for sample config to allow whereabouts use in-pod service account token instead of kubeconfig. Service account token refreshes hourly. (we faced similar issue with Multus, and switched to multus-thick deployment, it helped!)

To Reproduce
Steps to reproduce the behavior:

  1. Rotate oidc issuer key twice.
  2. Create pods that use whereabouts for IP allocation

Environment: Linux

  • Whereabouts version : v0.6.2
  • Kubernetes version (use kubectl version): 1.26.3
  • Network-attachment-definition: N/A
  • Whereabouts configuration (on the host):
    { "datastore": "kubernetes", "kubernetes": { "kubeconfig": "/etc/cni/net.d/whereabouts.d/whereabouts.kubeconfig" }, "reconciler_cron_expression": "30 4 * * *" }
  • OS (e.g. from /etc/os-release): Ubuntu 20.04
  • Kernel (e.g. uname -a): 5.15.0-1045
  • Others: N/A

Additional info / context
Add any other information / context about the problem here.

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

1 participant