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

fix: gpushare concurrent map read write #197

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

swartz-k
Copy link
Contributor

fix error as below

fatal error: concurrent map read and map write
{"level":"info","ts":"2023-01-11T09:58:45.234Z","caller":"cache/nodeinfo.go:340","msg":"info: try to find unhealthy node unhealthy-gpu-xxxxx"}
{"level":"info","ts":"2023-01-11T09:58:45.234Z","caller":"cache/nodeinfo.go:306","msg":"info: available GPU list map[0:23 1:23 2:11 3:5 4:23 5:23 6:23 7:23] before removing unhealty GPUs"}
{"level":"info","ts":"2023-01-11T09:58:45.234Z","caller":"cache/nodeinfo.go:311","msg":"info: available GPU list map[0:23 1:23 2:11 3:5 4:23 5:23 6:23 7:23] after removing unhealty GPUs"}
{"level":"info","ts":"2023-01-11T09:58:45.234Z","caller":"cache/nodeinfo.go:156","msg":"debug: AvailableGPUs: map[0:23 1:23 2:11 3:5 4:23 5:23 6:23 7:23] in node xxxx"}

goroutine 109 [running]:
github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare.(*Controller).syncPod(0xc0000c6000, {0xc01fef3fb0, 0x30})
   /Users/joker/go/src/github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare/controller.go:200 +0x40d
github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare.(*Controller).processNextWorkItem(0xc0000c6000)
   /Users/joker/go/src/github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare/controller.go:232 +0x16d
github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare.(*Controller).runWorker(0xc0004ac6a0?)
   /Users/joker/go/src/github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare/controller.go:182 +0x25
k8s.io/apimachinery/pkg/util/wait.BackoffUntil.func1(0x0?)
   /Users/joker/go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:157 +0x3e
k8s.io/apimachinery/pkg/util/wait.BackoffUntil(0x0?, {0x1a348e0, 0xc01a328900}, 0x1, 0xc0001150e0)
   /Users/joker/go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:158 +0xb6
k8s.io/apimachinery/pkg/util/wait.JitterUntil(0x0?, 0x3b9aca00, 0x0, 0x0?, 0x0?)
   /Users/joker/go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:135 +0x89
k8s.io/apimachinery/pkg/util/wait.Until(0x0?, 0x0?, 0x0?)
   /Users/joker/go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:92 +0x25
created by github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare.(*Controller).Run
   /Users/joker/go/src/github.com/AliyunContainerService/gpushare-scheduler-extender/pkg/gpushare/controller.go:168 +0x167

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

Successfully merging this pull request may close these issues.

1 participant