diff options
| author | Mark Stapp <mjs@voltanet.io> | 2018-11-12 15:57:03 -0500 |
|---|---|---|
| committer | Mark Stapp <mjs@voltanet.io> | 2018-11-21 10:38:08 -0500 |
| commit | 62b8bb7a1776ea98e5874a4a057617e335a7f77c (patch) | |
| tree | bd76e8af2363cff81492e93f132cbc4de019e669 /zebra/main.c | |
| parent | ad6aad4d0bc06f7711d05e1d05576ea25aac04c5 (diff) | |
zebra: separate netlink socket for dataplane
Use a separate netlink socket for the dataplane's updates, to
avoid races between the dataplane pthread and the zebra main
pthread. Revise zebra shutdown so that the dataplane netlink
socket is cleaned-up later, after all shutdown-time dataplane
work has been done.
Signed-off-by: Mark Stapp <mjs@voltanet.io>
Diffstat (limited to 'zebra/main.c')
| -rw-r--r-- | zebra/main.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/zebra/main.c b/zebra/main.c index e5160c1a51..5b5ee8259a 100644 --- a/zebra/main.c +++ b/zebra/main.c @@ -172,7 +172,7 @@ static void sigint(void) work_queue_free_and_null(&zebrad.lsp_process_q); vrf_terminate(); - ns_walk_func(zebra_ns_disabled); + ns_walk_func(zebra_ns_early_shutdown); zebra_ns_notify_close(); access_list_reset(); @@ -196,6 +196,9 @@ int zebra_finalize(struct thread *dummy) { zlog_info("Zebra final shutdown"); + /* Final shutdown of ns resources */ + ns_walk_func(zebra_ns_final_shutdown); + /* Stop dplane thread and finish any cleanup */ zebra_dplane_shutdown(); |
