Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FRR-BGP Extended Unified Management Framework #23

Merged
merged 12 commits into from
May 16, 2020

Conversation

karthikarum
Copy link

No description provided.

@venkatmahalingam venkatmahalingam marked this pull request as ready for review November 25, 2019 04:28
![FRR-BGP-REST-GET-SEQUENCE1](images/frr-bgp-rest-get-sequence1.jpg)

### 4.3.2 REST Get Sequence - State/Statistics
![FRR-BGP-REST-GET-SEQUENCE2](images/frr-bgp-rest-get-sequence2.jpg)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the communication mechanism between translib/transformer and bgpcfgd? I do not see this explained anywhere in the document. Also these flow diagrams need explanation.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the doc with "docker exec" command.

Copy link
Collaborator

@venkatmahalingam venkatmahalingam Dec 19, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a mention of event handling in the diagram section 4.1

## 3.1 Overview
The extended unified config and management framework for FRR-BGP in SONiC is represented in below diagram.

![FRR-BGP Unified Mgmt Framework](images/FRR-BGP-Unified-mgmt-frmwrk.png)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The state and statistics flow in this diagram does not match with the CLI and REST get flow diagram. In the flow diagrams the response is through bgpcfgd but in this diagram it is shown that the FRR directly talks to management framework. Only one can be right.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will fix this.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed the diagram, bgpcfgd is not involved for state/stats get.


5. KLISH CLI and REST clients provide extensive BGP configurations and hence there should not be any need for BGP configurations via vtysh.

6. In bgpcfgd register for Redis DB events for the BGP and other related objects, so as to translate the Redis DB events to FRR-BGP CLI commands to configure FRR-BGP, similarly, separate config daemons can be present to configure individual features like OSPF, BFD..etc
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

By FRR-BGP CLI command, we mean vtysh CLI commands right? If so will the vtysh shell be opened once from bgpcfgd or will it be opened for every single configuration command?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, will check the possibility in bgpcfgd and make the changes accordingly.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will check and fix accordingly.


6. In bgpcfgd register for Redis DB events for the BGP and other related objects, so as to translate the Redis DB events to FRR-BGP CLI commands to configure FRR-BGP, similarly, separate config daemons can be present to configure individual features like OSPF, BFD..etc

7. Update /usr/share/sonic/templates/bgpd.conf.j2 template for new FRR-BGP configurations supported in SONiC which will be used by sonic-cfggen to generate /etc/frr/bgpd.conf file.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we include the template here?

Copy link
Collaborator

@venkatmahalingam venkatmahalingam Dec 19, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, we're just enhancing the existing bgpd.conf.j2 for new configs.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, this is well known template file and already being used for BGP neighbors, peer range..etc

![FRR-BGP-CLI-SHOW-SEQUENCE1](images/frr-bgp-cli-show-sequence11.jpg)

### 4.2.2 CLI Show Sequence - State/Statistics
![FRR-BGP-CLI-SHOW-SEQUENCE2](images/frr-bgp-cli-show-sequence22.jpg)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Diagram shows translib sends a synchronous message to bgpcfgd which in turn runs vtysh command. What is the messaging used between translib and bgpcfgd?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will fix it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed the diagram, there is no bgpcfgd involvement for state/stats show.


6. For show commands that requires retrieval of state or statistics information the backend callback will fetch the data from FRR-BGP.

7. State/stats information is retried from FRR-BGP by issuing a show command to FRR BGP container and the output is returned in JSON format.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not in sync with flow diagram 4.2.2 - it shows translib sends a synchronous message to bgpcfgd to fetch state data.
Also, isn't direct container-to-container communication against SONiC design guidelines?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will fix it

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fixed now.

@venkatmahalingam venkatmahalingam changed the title Draft HLD - FRR-BGP Extended Unified Management Framework FRR-BGP Extended Unified Management Framework Dec 18, 2019
@venkatmahalingam venkatmahalingam merged commit 7351fb1 into master May 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants