Skip to content

Commit 9db146c

Browse files
committedFeb 15, 2023
do not remove link local route on ovn0 (kubeovn#2341)
1 parent eb6d0bb commit 9db146c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎pkg/daemon/controller.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ func getNicExistRoutes(nic netlink.Link, gateway string) ([]netlink.Route, error
623623

624624
func routeDiff(existRoutes []netlink.Route, cidrs []string) (toAdd []string, toDel []string) {
625625
for _, route := range existRoutes {
626-
if route.Scope == netlink.SCOPE_LINK {
626+
if route.Scope == netlink.SCOPE_LINK || route.Dst == nil || route.Dst.IP.IsLinkLocalUnicast() {
627627
continue
628628
}
629629

0 commit comments

Comments
 (0)
Please sign in to comment.