Skip to content

Commit

Permalink
Merge pull request #952 from hzxuzhonghu/fix-bpfloader
Browse files Browse the repository at this point in the history
Fix when bpf loader failed, it should have a chance to dettach bpf pr…
  • Loading branch information
kmesh-bot authored Oct 14, 2024
2 parents e83536b + 241e679 commit 588aa98
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion daemon/manager/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,12 @@ func Execute(configs *options.BootstrapConfigs) error {
}

bpfLoader := bpf.NewBpfLoader(configs.BpfConfig)
// there could be a case that bpf loader partially start failed, we still need to stop it, otherwise it cannot recover
// https://github.com/kmesh-net/kmesh/issues/951
defer bpfLoader.Stop()
if err := bpfLoader.Start(); err != nil {
return err
}
defer bpfLoader.Stop()
log.Info("bpf loader start successfully")

stopCh := make(chan struct{})
Expand Down

0 comments on commit 588aa98

Please sign in to comment.