Skip to content

Conversation

@donaldsharp
Copy link
Member

See 2nd commit for a description of what is being done, as that it holds the design I worked towards.

Start the ability for FRR to interact with a system manager. Create test commands, ensure that they work.

I want to create some code in zebra that should not have access to rib.h
as that it does not need to know anything about rib operations.  Let's
move the MTYPE(ZEBRA) out of rib.h to allow the new files to not
need rib.h

Signed-off-by: Donald Sharp <[email protected]>
Add a high-level system-manager design doc and how I plan
to go about doing this.  Additionally it documents a bunch
of simple steps to get this working.

Signed-off-by: Donald Sharp <[email protected]>
This code does nothing more than start the zebra system-manager
pthread and allow it to stop on shutdown.

Signed-off-by: Donald Sharp <[email protected]>
The vscode editor wants to be informed about how FRR is built.
Document how to make this happen to allow vscode to operate
a bit better.

Signed-off-by: Donald Sharp <[email protected]>
Add a initial context passing structure for the new sysmgr
code.  This is not really used at this point in time.

Signed-off-by: Donald Sharp <[email protected]>
Allow the zebra master pthread to send a test message to the
system manager pthread.

Signed-off-by: Donald Sharp <[email protected]>
Let's add debugs so that we can follow what is going on.

Signed-off-by: Donald Sharp <[email protected]>
Introduce this event into the system and add test code harness
to show that it is received and handled.

Signed-off-by: Donald Sharp <[email protected]>
Allow interested parties to receive notification when a PORTS_UP
or PORTS_DOWN event has happened.

Signed-off-by: Donald Sharp <[email protected]>
Add `sharp watch sysmgr`.  This way we should be getting and seeing
all sysmgr events.

Signed-off-by: Donald Sharp <[email protected]>
Add a `show sharp sysmgr` command that will display information about
the last sysmgr notification received.

Signed-off-by: Donald Sharp <[email protected]>
Add a test that shows that zebra is able to send a sysmgr notifcation
and upper level protocols can receive it.

Signed-off-by: Donald Sharp <[email protected]>
@mjstapp
Copy link
Contributor

mjstapp commented Jan 16, 2026

I guess my initial reaction to the document is that I don't understand what this is actually ... going to do?

Is zebra going to notice that "warm boot" is occurring? If so, what
will zebra do differently? Do any other daemons need to know about
that event, and if so, what will it/they do? Does zebra need to
distribute an event via zapi? Does it need to track who has received
and acknowledged the event? I'd rather see that proposal as a
standalone design to evaluate.

Similarly, what does "port reset" mean, and what will change in zebra
if ... it is happening? Again, I'd rather see that proposal, and
understand what that would mean for zebra, independently.

I think I understand the "GR" event you've described, but that could
just be a hook function, right? And that makes me wonder about all the
rest: I don't quite see why we'd need a new pthread and assorted
machinery just to set a boolean (for "warm reboot"), or to have zebra
call a "GR done" hook function.

I understand the machinery that's proposed, but I think it's premature
to choose the machinery to accomplish something when ... what is to be
done isn't clear (to me).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants