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

[BUG] serviceCIDR get failed #4307

Open
0x0034 opened this issue Nov 22, 2024 · 4 comments · May be fixed by #4366
Open

[BUG] serviceCIDR get failed #4307

0x0034 opened this issue Nov 22, 2024 · 4 comments · May be fixed by #4366
Assignees
Labels
kind/support If you need any helps
Milestone

Comments

@0x0034
Copy link

0x0034 commented Nov 22, 2024

Spiderpool Version

0.9.7

kubernetes Version

1.21.14

Main CNI

macvlan

bug description

Failed to create pod sandbox: rpc error: code = Unknown desc = [failed to set up sandbox container "8c4c6dd6fbe8e3e8d87344035785c2c4065febc102e9fa36c0eb360bfca169fc" network for pod "coredns-646db9d5f6-c5zvl": networkPlugin cni failed to set up pod "coredns-646db9d5f6-c5zvl_kube-system" network: [kube-system/coredns-646db9d5f6-c5zvl/:macvlan-conf]: error adding container to network "macvlan-conf": Link not found, failed to clean up sandbox container "8c4c6dd6fbe8e3e8d87344035785c2c4065febc102e9fa36c0eb360bfca169fc" network for pod "coredns-646db9d5f6-c5zvl": networkPlugin cni failed to teardown pod "coredns-646db9d5f6-c5zvl_kube-system" network: delegateDel: error invoking ConflistDel - "macvlan-conf": conflistDel: error in getting result from DelNetworkList: validation failure list:
serviceCIDR in body is required]

What did you expect to happen?

No response

How to reproduce it (as minimally and precisely as possible)

No response

Additional Context

  • controller logs
{"level":"INFO","ts":"2024-11-21T12:08:42.917Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:59","msg":"CommitVersion: 36b96b7ab997f8f57bd43ad03880a9319b1cf149"}
{"level":"INFO","ts":"2024-11-21T12:08:42.917Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:62","msg":"CommitTime: 2024-09-26T13:33:23+08:00"}
{"level":"INFO","ts":"2024-11-21T12:08:42.917Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:65","msg":"AppVersion: v0.9.7"}
{"level":"INFO","ts":"2024-11-21T12:08:42.919Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:71","msg":"maxprocs: Updating GOMAXPROCS=1: using minimum allowed GOMAXPROCS"}
{"level":"INFO","ts":"2024-11-21T12:08:42.919Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:81","msg":"Spiderpool-controller config: {CommitVersion:36b96b7ab997f8f57bd43ad03880a9319b1cf149 CommitTime:2024-09-26T13:33:23+08:00 AppVersion:v0.9.7 ConfigPath:/tmp/spiderpool/config-map/conf.yml TlsServerCertPath:/etc/tls/tls.crt TlsServerKeyPath:/etc/tls/tls.key LogLevel:info EnableMetric:false EnableDebugLevelMetric:false MetricRenewPeriod:120 HttpPort:5720 MetricHttpPort:5721 WebhookPort:5722 GopsListenPort:5724 PyroscopeAddress: DefaultCniConfDir:/etc/cni/net.d CiliumConfigName:kube-system/cilium-config ControllerPodNamespace:kube-system ControllerPodName:spiderpool-controller-6c8557db87-wxj8p DefaultCoordinatorName:default LeaseDuration:15 LeaseRenewDeadline:10 LeaseRetryPeriod:2 LeaseRetryGap:1 IPPoolMaxAllocatedIPs:5000 SubnetInformerResyncPeriod:300 SubnetInformerWorkers:5 SubnetInformerMaxWorkqueueLength:10000 SubnetAppControllerWorkers:5 IPPoolInformerResyncPeriod:300 IPPoolInformerWorkers:3 IPPoolInformerMaxWorkQueueLength:10000 WorkQueueMaxRetries:500 WorkQueueRequeueDelayDuration:5 CoordinatorInformerResyncPeriod:60 EnableMultusConfig:true MultusConfigInformerResyncPeriod:60 EnableCoordinator:true EnableIPv4:true EnableIPv6:true EnableStatefulSet:true EnableKubevirtStaticIP:true EnableSpiderSubnet:true ClusterSubnetDefaultFlexibleIPNum:1}"}
{"level":"INFO","ts":"2024-11-21T12:08:42.920Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:94","msg":"gops is listening on 127.0.0.1:5724"}
{"level":"INFO","ts":"2024-11-21T12:08:42.920Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:133","msg":"Begin to initialize spiderpool-controller metrics HTTP server"}
{"level":"INFO","ts":"2024-11-21T12:08:42.920Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:136","msg":"Begin to initialize spiderpool-controller runtime manager"}
{"level":"INFO","ts":"2024-11-21T12:08:42.935Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:268","msg":"Begin to initialize StatefulSet manager"}
{"level":"INFO","ts":"2024-11-21T12:08:42.936Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:164","msg":"Starting spiderpool-controller runtime manager"}
{"level":"INFO","ts":"2024-11-21T12:08:42.936Z","logger":"Lease-Lock-Election","caller":"election/lease_election.go:163","msg":"'kube-system/spiderpool-controller-leases/spiderpool-controller-6c8557db87-wxj8p' is trying to elect"}
I1121 12:08:42.937035       1 leaderelection.go:250] attempting to acquire leader lease kube-system/spiderpool-controller-leases...
{"level":"INFO","ts":"2024-11-21T12:08:43.037Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:174","msg":"Begin to initialize OpenAPI HTTP server"}
{"level":"INFO","ts":"2024-11-21T12:08:43.040Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:190","msg":"Begin to initialize IP GC Manager"}
{"level":"INFO","ts":"2024-11-21T12:08:43.041Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:193","msg":"Set spiderpool-controller Startup probe ready"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"spiderpool-controller","caller":"cmd/http_server.go:28","msg":"Serving spiderpool controller API at http://[[::]:5720]"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/gc_manager.go:165","msg":"running IP garbage collection"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","caller":"limiter/queue.go:135","msg":"Starting limiter"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/pod_informer.go:17","msg":"try to register pod informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:28","msg":"starting trace pod worker"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:57","msg":"receive CLI GC request, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:96","msg":"Start checking if IPPool.Status.AllocatedIPs and the endpoint need to be garbage collected ","garbage collected trace":1}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:96","msg":"Start checking if IPPool.Status.AllocatedIPs and the endpoint need to be garbage collected ","garbage collected trace":2}
{"level":"INFO","ts":"2024-11-21T12:08:43.047Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:96","msg":"Start checking if IPPool.Status.AllocatedIPs and the endpoint need to be garbage collected ","garbage collected trace":3}
{"level":"INFO","ts":"2024-11-21T12:08:43.051Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:473","msg":"Begin to set up Coordinator informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.051Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:489","msg":"Begin to set up IPPool informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.051Z","logger":"SpiderIPPool-Informer","caller":"ippoolmanager/ippool_informer.go:77","msg":"try to register SpiderIPPool informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.051Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:509","msg":"Begin to set up Subnet informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.051Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:522","msg":"Begin to set up auto-created IPPool controller"}
{"level":"INFO","ts":"2024-11-21T12:08:43.052Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationcontroller/app_controller.go:106","msg":"try to register SpiderSubnet App informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.052Z","logger":"spiderpool-controller","caller":"cmd/daemon.go:547","msg":"Begin to set up MultusConfig informer"}
{"level":"INFO","ts":"2024-11-21T12:08:43.052Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:73","msg":"try to register MultusConfig informer"}
I1121 12:08:59.906158       1 leaderelection.go:260] successfully acquired lease kube-system/spiderpool-controller-leases
{"level":"INFO","ts":"2024-11-21T12:08:59.906Z","logger":"Lease-Lock-Election","caller":"election/lease_election.go:133","msg":"leader elected: kube-system/spiderpool-controller-leases/spiderpool-controller-6c8557db87-wxj8p"}
{"level":"INFO","ts":"2024-11-21T12:09:00.059Z","logger":"IP-GarbageCollection","caller":"gcmanager/pod_informer.go:49","msg":"create Pod informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.059Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:57","msg":"receive CLI GC request, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:09:00.063Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:125","msg":"Initialize Dynamic informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:129","msg":"Initialize Subnet informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:250","msg":"Starting Subnet informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:252","msg":"Waiting for informer caches to sync"}
I1121 12:09:00.064185       1 shared_informer.go:311] Waiting for caches to sync for SpiderSubnet
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationcontroller/app_controller.go:138","msg":"create SpiderSubnet App informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/deployment_informer.go:15","msg":"Setting up Deployment handlers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/replicaset_informer.go:15","msg":"Setting up ReplicaSet handlers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/statefulset_informer.go:15","msg":"Setting up StatefulSet handlers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/daemonset_informer.go:15","msg":"Setting up DaemonSet handlers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/job_informer.go:15","msg":"Setting up Job informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderSubnet-Application-Controllers","caller":"applicationinformers/cronjob_informer.go:15","msg":"Setting up CronJob handlers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:105","msg":"create MultusConfig informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:168","msg":"Initialize Coordinator informer"}
{"level":"INFO","ts":"2024-11-21T12:09:00.064Z","logger":"SpiderIPPool-Informer","caller":"ippoolmanager/ippool_informer.go:109","msg":"create SpiderIPPool informer"}
{"level":"WARN","ts":"2024-11-21T12:09:00.098Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:245","msg":"ServiceCIDR feature is unavailable in your cluster, Don't start the serviceCIDR informer"}
I1121 12:09:00.098515       1 shared_informer.go:311] Waiting for caches to sync for SpiderCoordinator
I1121 12:09:00.164984       1 shared_informer.go:318] Caches are synced for SpiderSubnet
{"level":"INFO","ts":"2024-11-21T12:09:00.164Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:257","msg":"Starting workers"}
{"level":"INFO","ts":"2024-11-21T12:09:00.165Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:262","msg":"Starting dynamic informer worker"}
{"level":"INFO","ts":"2024-11-21T12:09:00.165Z","logger":"Subnet-Informer","caller":"subnetmanager/subnet_informer.go:265","msg":"Started workers"}
I1121 12:09:00.199232       1 shared_informer.go:318] Caches are synced for SpiderCoordinator
{"level":"INFO","ts":"2024-11-21T12:09:00.199Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.502Z","logger":"Coordinator-Webhook.Mutating","caller":"coordinatormanager/coordinator_mutate.go:24","msg":"Start to mutate Coordinator","CoordinatorName":"default","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:09:03.502Z","logger":"Coordinator-Webhook.Mutating","caller":"coordinatormanager/coordinator_mutate.go:78","msg":"Add finalizer spiderpool.spidernet.io","CoordinatorName":"default","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:09:03.519Z","logger":"MultusConfig-Webhook.Mutating","caller":"multuscniconfig/multusconfig_mutate.go:17","msg":"Start to mutate SpiderMultusConfig","SpiderMultusConfig":"macvlan-conf"}
{"level":"INFO","ts":"2024-11-21T12:09:03.532Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:469","msg":"Trying to fetch the ClusterCIDR from kube-system/kubeadm-config","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.532Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:471","msg":"kubeadm-config configMap k8sPodCIDR [], k8sServiceCIDR []","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.532Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.532Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.532Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:441","msg":"Patching coordinator's status from {  [] []} to {Synced  [] []}","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.547Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:446","msg":"Success to patch coordinator's status to {Synced  [] []}","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.547Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.550Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:469","msg":"Trying to fetch the ClusterCIDR from kube-system/kubeadm-config","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.551Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:471","msg":"kubeadm-config configMap k8sPodCIDR [], k8sServiceCIDR []","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.551Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.551Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.551Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-21T12:09:03.637Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:333","msg":"try to create net-attach-def &{{ } {macvlan-conf  kube-system    0 0001-01-01 00:00:00 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0013d882b 0xc0013d882a}] [] []} {}} for MultusConfg kube-system/macvlan-conf"}
{"level":"INFO","ts":"2024-11-21T12:10:00.153Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc000b631aa 0xc000b631ab}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:10:00.186Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:11:00.154Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0014d28aa 0xc0014d28ab}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:11:00.187Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:12:00.155Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0008e3c59 0xc0008e3c5a}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:12:00.188Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:13:00.155Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0013798ca 0xc0013798cb}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:13:00.189Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:14:00.156Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0001e715a 0xc0001e715b}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:14:00.189Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:14:51.086Z","logger":"IPPool-Webhook.Mutating","caller":"ippoolmanager/ippool_mutate.go:26","msg":"Start to mutate IPPool","IPPoolName":"ippool-test","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:14:51.086Z","logger":"IPPool-Webhook.Mutating","caller":"ippoolmanager/ippool_mutate.go:35","msg":"Add finalizer spiderpool.spidernet.io","IPPoolName":"ippool-test","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:14:51.086Z","logger":"IPPool-Webhook.Mutating","caller":"ippoolmanager/ippool_mutate.go:50","msg":"Set 'spec.ipVersion' to 4","IPPoolName":"ippool-test","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:14:51.086Z","logger":"IPPool-Webhook.Mutating","caller":"ippoolmanager/ippool_mutate.go:63","msg":"Set label ipam.spidernet.io/ippool-cidr: 10-215-20-0-22","IPPoolName":"ippool-test","Operation":"DEFAULT"}
{"level":"INFO","ts":"2024-11-21T12:14:51.205Z","logger":"SpiderIPPool-Informer","caller":"ippoolmanager/ippool_informer.go:316","msg":"initial SpiderIPPool 'ippool-test' status AllocatedIPCount to 0"}
{"level":"INFO","ts":"2024-11-21T12:14:59.593Z","logger":"MultusConfig-Webhook.Mutating","caller":"multuscniconfig/multusconfig_mutate.go:17","msg":"Start to mutate SpiderMultusConfig","SpiderMultusConfig":"macvlan-conf"}
{"level":"INFO","ts":"2024-11-21T12:15:00.157Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:323","msg":"try to update net-attach-def &{{NetworkAttachmentDefinition k8s.cni.cncf.io/v1} {macvlan-conf  kube-system  8995f3db-f172-465d-bae9-7e97c8d8037b 7339 1 2024-11-21 12:09:03 +0000 UTC <nil> <nil> map[] map[] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 5cf9a93d-de88-4ddf-8e5c-9d70188ba939 0xc0015b826a 0xc0015b826b}] [] [{spiderpool-controller Update k8s.cni.cncf.io/v1 2024-11-21 12:09:03 +0000 UTC FieldsV1 {\"f:metadata\":{\"f:ownerReferences\":{\".\":{},\"k:{\\\"uid\\\":\\\"5cf9a93d-de88-4ddf-8e5c-9d70188ba939\\\"}\":{\".\":{},\"f:apiVersion\":{},\"f:blockOwnerDeletion\":{},\"f:controller\":{},\"f:kind\":{},\"f:name\":{},\"f:uid\":{}}}},\"f:spec\":{\".\":{},\"f:config\":{}}} }]} {}}"}
{"level":"INFO","ts":"2024-11-21T12:15:00.190Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:15:09.119Z","logger":"MultusConfig-Webhook.Mutating","caller":"multuscniconfig/multusconfig_mutate.go:17","msg":"Start to mutate SpiderMultusConfig","SpiderMultusConfig":"macvlan-conf"}
{"level":"INFO","ts":"2024-11-21T12:15:09.128Z","logger":"MultusConfig-Informer","caller":"multuscniconfig/multusconfig_informer.go:333","msg":"try to create net-attach-def &{{ } {macvlan-conf  kube-system    0 0001-01-01 00:00:00 +0000 UTC <nil> <nil> map[] map[kubectl.kubernetes.io/last-applied-configuration:{\"apiVersion\":\"spiderpool.spidernet.io/v2beta1\",\"kind\":\"SpiderMultusConfig\",\"metadata\":{\"annotations\":{},\"name\":\"macvlan-conf\",\"namespace\":\"kube-system\"},\"spec\":{\"cniType\":\"macvlan\",\"macvlan\":{\"master\":[\"bond0\"]}}}\n] [{spiderpool.spidernet.io/v2beta1 SpiderMultusConfig macvlan-conf 46d4c2f5-46ed-404c-b8e9-5925ccc7ed4c 0xc0015b94e9 0xc0015b94e8}] [] []} {{\"cniVersion\":\"0.3.1\",\"name\":\"macvlan-conf\",\"plugins\":[{\"type\":\"macvlan\",\"master\":\"bond0\",\"mode\":\"bridge\",\"ipam\":{\"type\":\"spiderpool\"}},{\"detectIPConflict\":false,\"detectGateway\":false,\"tunePodRoutes\":true,\"mode\":\"auto\",\"type\":\"coordinator\",\"txQueueLen\":0}]}}} for MultusConfg kube-system/macvlan-conf"}
{"level":"INFO","ts":"2024-11-21T12:15:33.200Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:78","msg":"the graceful deletion period of pod 'kube-system/coredns-564749475f-559jc' is over, try to release the IP address.","podEntry tracing-reason":"Deleted"}
{"level":"INFO","ts":"2024-11-21T12:15:33.300Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:105","msg":"SpiderEndpoint 'kube-system/coredns-564749475f-559jc' not found, maybe already cleaned by cmdDel or ScanAll","garbage collected trace":1}
{"level":"INFO","ts":"2024-11-21T12:15:38.201Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:78","msg":"the graceful deletion period of pod 'kube-system/coredns-78687b8f5d-gczkf' is over, try to release the IP address.","podEntry tracing-reason":"Deleted"}
{"level":"INFO","ts":"2024-11-21T12:15:38.201Z","logger":"IP-GarbageCollection","caller":"gcmanager/tracePod_worker.go:105","msg":"SpiderEndpoint 'kube-system/coredns-78687b8f5d-gczkf' not found, maybe already cleaned by cmdDel or ScanAll","garbage collected trace":2}
{"level":"INFO","ts":"2024-11-21T12:16:00.190Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:17:00.191Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:18:00.191Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:19:00.192Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:19:01.061Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:20:00.192Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:21:00.193Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:22:00.194Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:23:00.195Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:24:00.196Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:25:00.197Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:26:00.197Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:27:00.198Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:28:00.198Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:29:00.199Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:29:01.062Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:30:00.200Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:31:00.200Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:32:00.200Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:33:00.201Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:34:00.201Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:35:00.201Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:36:00.201Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:37:00.202Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:38:00.202Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:39:00.203Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:39:01.062Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:40:00.203Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:41:00.204Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:42:00.204Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:43:00.205Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:44:00.206Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:45:00.206Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:46:00.206Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:47:00.207Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:48:00.207Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:49:00.208Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:49:01.063Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
{"level":"INFO","ts":"2024-11-21T12:50:00.208Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:51:00.208Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:52:00.209Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:53:00.209Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:54:00.210Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:55:00.211Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:56:00.212Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:57:00.212Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:58:00.213Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:59:00.214Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-21T12:59:01.064Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
  • spidercoordinator
$ kubectl get spidercoordinator default -o yaml
apiVersion: spiderpool.spidernet.io/v2beta1
kind: SpiderCoordinator
metadata:
  creationTimestamp: "2024-11-21T12:09:03Z"
  finalizers:
  - spiderpool.spidernet.io
  generation: 1
  name: default
  resourceVersion: "7337"
  uid: 0f0d7c9f-c7f2-47a6-8ce5-349c8fdd221b
spec:
  detectGateway: false
  detectIPConflict: false
  hijackCIDR:
  - 169.254.0.0/16
  hostRPFilter: 0
  hostRuleTable: 500
  mode: auto
  podCIDRType: auto
  podDefaultRouteNIC: ""
  podMACPrefix: ""
  podRPFilter: 0
  tunePodRoutes: true
  txQueueLen: 0
status:
  overlayPodCIDR: []
  phase: Synced

问题补充:
当删除kubeadm-config 后 controller 可以正常的从 kube-controller-manager 中获取 serviceCIDR . controller 日志如下

{"level":"WARN","ts":"2024-11-22T02:55:22.286Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:473","msg":"failed to get kube-system/kubeadm-config: configmaps \"kubeadm-config\" not found, trying to fetch the ClusterCIDR from kube-controller-manager","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.309Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.309Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.309Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:441","msg":"Patching coordinator's status from {Synced  [] []} to {Synced  [] [245.100.128.0/18]}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.321Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:446","msg":"Success to patch coordinator's status to {Synced  [] [245.100.128.0/18]}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.321Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"WARN","ts":"2024-11-22T02:55:22.324Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:473","msg":"failed to get kube-system/kubeadm-config: configmaps \"kubeadm-config\" not found, trying to fetch the ClusterCIDR from kube-controller-manager","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.329Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.329Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:22.329Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.289Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:469","msg":"Trying to fetch the ClusterCIDR from kube-system/kubeadm-config","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.289Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:471","msg":"kubeadm-config configMap k8sPodCIDR [], k8sServiceCIDR []","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.289Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.289Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.289Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:441","msg":"Patching coordinator's status from {Synced  [] [245.100.128.0/18]} to {Synced  [] []}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.299Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:446","msg":"Success to patch coordinator's status to {Synced  [] []}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.299Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.301Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:469","msg":"Trying to fetch the ClusterCIDR from kube-system/kubeadm-config","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.301Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:471","msg":"kubeadm-config configMap k8sPodCIDR [], k8sServiceCIDR []","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.301Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.301Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:55:28.301Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:56:00.708Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-22T02:57:00.709Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-22T02:58:00.709Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"WARN","ts":"2024-11-22T02:58:36.901Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:473","msg":"failed to get kube-system/kubeadm-config: configmaps \"kubeadm-config\" not found, trying to fetch the ClusterCIDR from kube-controller-manager","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.920Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.920Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.920Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:441","msg":"Patching coordinator's status from {Synced  [] []} to {Synced  [] [245.100.128.0/18]}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.927Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:446","msg":"Success to patch coordinator's status to {Synced  [] [245.100.128.0/18]}","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.927Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"ConfigMap/kubeadm-config","Operation":"PROCESS"}
{"level":"WARN","ts":"2024-11-22T02:58:36.935Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:473","msg":"failed to get kube-system/kubeadm-config: configmaps \"kubeadm-config\" not found, trying to fetch the ClusterCIDR from kube-controller-manager","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.940Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:498","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.940Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:522","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:58:36.940Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-22T02:59:00.709Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:322","msg":"status have no changes, ignore add it to workqueue","CoordinatorName":"default","Operation":"UPDATE"}
{"level":"INFO","ts":"2024-11-22T02:59:01.121Z","logger":"IP-GarbageCollection","caller":"gcmanager/scanAll_IPPool.go:50","msg":"trigger default GC interval, execute scan all right now!"}
  • kubeadm-config
apiVersion: v1
data:
  ClusterConfiguration: |
    apiServer:
      certSANs:
      - 127.0.0.1
      - apiserver.cluster.local
      - 10.103.97.2
      - 10.215.45.124
      - 10.215.45.91
      - 10.215.45.144
      extraArgs:
        audit-log-format: json
        audit-log-maxage: "7"
        audit-log-maxbackup: "10"
        audit-log-maxsize: "100"
        audit-log-path: /var/log/kubernetes/audit.log
        audit-policy-file: /etc/kubernetes/audit-policy.yml
        authorization-mode: Node,RBAC
        enable-aggregator-routing: "true"
        feature-gates: EphemeralContainers=true,TTLAfterFinished=true
      extraVolumes:
      - hostPath: /etc/kubernetes
        mountPath: /etc/kubernetes
        name: audit
        pathType: DirectoryOrCreate
      - hostPath: /var/log/kubernetes
        mountPath: /var/log/kubernetes
        name: audit-log
        pathType: DirectoryOrCreate
      - hostPath: /etc/localtime
        mountPath: /etc/localtime
        name: localtime
        pathType: File
        readOnly: true
      timeoutForControlPlane: 4m0s
    apiVersion: kubeadm.k8s.io/v1beta2
    certificatesDir: /etc/kubernetes/pki
    clusterName: kubernetes
    controlPlaneEndpoint: apiserver.cluster.local:6443
    controllerManager:
      extraArgs:
        bind-address: 0.0.0.0
        cluster-signing-duration: 876000h
        feature-gates: EphemeralContainers=true,TTLAfterFinished=true
      extraVolumes:
      - hostPath: /etc/localtime
        mountPath: /etc/localtime
        name: localtime
        pathType: File
        readOnly: true
    dns:
      type: CoreDNS
    etcd:
      local:
        dataDir: /var/lib/etcd
        extraArgs:
          listen-metrics-urls: http://0.0.0.0:2381
    imageRepository: k8s.gcr.io
    kind: ClusterConfiguration
    kubernetesVersion: v1.21.14
    networking:
      dnsDomain: cluster.local
      podSubnet: 10.215.22.0/24
      serviceSubnet: 245.100.128.0/18
    scheduler:
      extraArgs:
        bind-address: 0.0.0.0
        feature-gates: EphemeralContainers=true,TTLAfterFinished=true
      extraVolumes:
      - hostPath: /etc/localtime
        mountPath: /etc/localtime
        name: localtime
        pathType: File
        readOnly: true
  ClusterStatus: |
    apiEndpoints:
      qabb-qa-kubernetes20:
        advertiseAddress: 10.215.45.124
        bindPort: 6443
      qabb-qa-kubernetes21:
        advertiseAddress: 10.215.45.91
        bindPort: 6443
      qabb-qa-kubernetes22:
        advertiseAddress: 10.215.45.144
        bindPort: 6443
    apiVersion: kubeadm.k8s.io/v1beta2
    kind: ClusterStatus
kind: ConfigMap
metadata:
  name: kubeadm-config
  namespace: kube-system
@cyclinder
Copy link
Collaborator

Thanks for the report @0x0034, We'll look into it further.

@weizhoublue weizhoublue added this to the v1.0.0 milestone Nov 28, 2024
@ty-dc ty-dc added the priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. label Nov 28, 2024
@cyclinder
Copy link
Collaborator

Hi @0x0034, I can't reproduce your issue by using your kubeadm-config, what's your k8s version? and can you run the command kubectl get servicecidr -A? thanks.

{"level":"INFO","ts":"2024-11-28T08:39:59.434Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:469","msg":"Trying to fetch the ClusterCIDR from kube-system/kubeadm-config","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-28T08:39:59.434Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:471","msg":"kubeadm-config configMap k8sPodCIDR [10.215.22.0/24], k8sServiceCIDR [245.100.128.0/18]","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-28T08:39:59.434Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:499","msg":"Detect podCIDRType is: none, try to update podCIDR","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-28T08:39:59.434Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:523","msg":"unable to list the serviceCIDR resources: the kubernetes serviceCIDR is disabled, update service cidr from cluster service cidr","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
{"level":"INFO","ts":"2024-11-28T08:39:59.434Z","logger":"Coordinator-Informer","caller":"coordinatormanager/coordinator_informer.go:425","msg":"Succeed to SYNC","Event Key":"SpiderCoordinator/default","Operation":"PROCESS"}
apiVersion: spiderpool.spidernet.io/v2beta1
kind: SpiderCoordinator
metadata:
  creationTimestamp: "2024-11-28T07:25:20Z"
  finalizers:
  - spiderpool.spidernet.io
  generation: 2
  name: default
  resourceVersion: "344481"
  uid: a52038be-3fe8-4929-8a06-64c69ea3c777
spec:
  detectGateway: false
  detectIPConflict: false
  hijackCIDR:
  - 169.254.0.0/16
  hostRPFilter: 0
  hostRuleTable: 500
  mode: auto
  podCIDRType: none
  podDefaultRouteNIC: ""
  podMACPrefix: ""
  podRPFilter: 0
  tunePodRoutes: true
  txQueueLen: 0
  vethLinkAddress: ""
status:
  overlayPodCIDR: []
  phase: Synced
  serviceCIDR:
  - 245.100.128.0/18

@cyclinder cyclinder added kind/support If you need any helps and removed kind/bug priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. labels Nov 28, 2024
@0x0034
Copy link
Author

0x0034 commented Dec 6, 2024

the kubernetes version is 1.21.14 , and build cluster by sealos , i can provider the build command

kubernetes version: 1.21.14
sealos version: 4.3.7

  • Clusterfile
apiVersion: apps.sealos.io/v1beta1
kind: Cluster
metadata:
  creationTimestamp: null
  name: qa-lab
spec:
  hosts:
    - ips:
        - 10.215.45.124:22
        - 10.215.45.91:22
        - 10.215.45.144:22
      roles:
        - master
        - amd64
    - ips:
        - 10.215.20.33:22
      roles:
        - node
        - amd64
  image:
    - registry.cn-shanghai.aliyuncs.com/labring/kubernetes-docker:v1.21.14
    - registry.cn-shanghai.aliyuncs.com/labring/helm:v3.15.4
  ssh:
    passwd: xxx
    pk: /root/.ssh/id_rsa
    port: 22
    user: root
status: {}
---
apiVersion: kubeadm.k8s.io/v1beta2
kind: ClusterConfiguration
networking:
  dnsDomain: cluster.local
  serviceSubnet: 245.100.128.0/18
  podSubnet: 10.215.22.0/24
  scheduler: {}
sealos apply -f Clusterfile

you can build cluster by above command , i hope can help you recurrence the bug

@0x0034
Copy link
Author

0x0034 commented Dec 8, 2024

#4366 @cyclinder

@cyclinder cyclinder linked a pull request Dec 10, 2024 that will close this issue
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/support If you need any helps
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants