Commit b3b380e
fix: avoid OVN northd "No path for static route" warning on startup
During controller startup, default gateway static routes (0.0.0.0/0 and
::/0) were added to the OVN logical router before the join subnet's
Logical Router Port was created, causing OVN northd to warn about
unreachable next hops.
This fix ensures routes are only added after the join subnet's OVN
Logical Switch and LRP exist:
1. Remove addNodeGatewayStaticRoute() call from syncNodeRoutes() which
runs during init phase before any OVN logical switches are created.
2. Add LogicalSwitchExists check in handleAddOrUpdateVpc() to requeue
the VPC if the join subnet's logical switch is not yet ready, avoiding
the race between VPC worker and Subnet worker.
3. Remove redundant addNodeGatewayStaticRoute() call from handleAddNode()
since handleAddOrUpdateVpc() already manages default route reconciliation
as part of VPC route diffing. Also remove the now-unused function.
Signed-off-by: Mengxin Liu <liumengxinfly@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Mengxin Liu <liumengxinfly@gmail.com>1 parent 7cb33fa commit b3b380e
3 files changed
+11
-45
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
904 | 904 | | |
905 | 905 | | |
906 | 906 | | |
907 | | - | |
908 | | - | |
909 | | - | |
910 | | - | |
911 | 907 | | |
912 | 908 | | |
913 | 909 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
245 | | - | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | 244 | | |
250 | 245 | | |
251 | 246 | | |
| |||
918 | 913 | | |
919 | 914 | | |
920 | 915 | | |
921 | | - | |
922 | | - | |
923 | | - | |
924 | | - | |
925 | | - | |
926 | | - | |
927 | | - | |
928 | | - | |
929 | | - | |
930 | | - | |
931 | | - | |
932 | | - | |
933 | | - | |
934 | | - | |
935 | | - | |
936 | | - | |
937 | | - | |
938 | | - | |
939 | | - | |
940 | | - | |
941 | | - | |
942 | | - | |
943 | | - | |
944 | | - | |
945 | | - | |
946 | | - | |
947 | | - | |
948 | | - | |
949 | | - | |
950 | | - | |
951 | | - | |
952 | | - | |
953 | | - | |
954 | | - | |
955 | | - | |
956 | | - | |
957 | 916 | | |
958 | 917 | | |
959 | 918 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
383 | 383 | | |
384 | 384 | | |
385 | 385 | | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
386 | 397 | | |
387 | 398 | | |
388 | 399 | | |
| |||
0 commit comments