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

[docker-fpm-frr]: Generate separated staticd.conf for staticd #3306

Merged
merged 4 commits into from
Aug 16, 2019
Merged

[docker-fpm-frr]: Generate separated staticd.conf for staticd #3306

merged 4 commits into from
Aug 16, 2019

Conversation

shikenghua
Copy link
Contributor

Staticd was separated out from zebra after frr-6.0 to isolate static route handling.
If staticd.conf is missing, it will take zebra.conf for backward compatible. In this case, many ERR logs will be generated because it doesn't recognize other CLI commands in zebra.conf except those for static route.
This may cause some Ansible tests fail because of the loganalyzer found errors in syslog.

- What I did
Generate separated staticd.conf for staticd

- How I did it
Generate staticd.conf by templates/staticd.conf.j2 with config DB data

- How to verify it
Add MGMT_INTERFACE with gwaddr in config_db.json. After reboot, check whether the staticd.conf is generated in /etc/frr/ with correct content and no staticd ERR message should be found in syslog.

- Description for the changelog
Generate staticd.conf by templates/staticd.conf.j2 with config DB data

- A picture of a cute animal (not mandatory but encouraged)

Generate staticd.conf by templates/staticd.conf.j2 with config DB data
@pavel-shirshov
Copy link
Contributor

retest this please

Copy link
Contributor

@pavel-shirshov pavel-shirshov left a comment

Choose a reason for hiding this comment

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

Good idea.
But do you think staticd support password and logging options?

dockers/docker-fpm-frr/staticd.conf.j2 Show resolved Hide resolved
dockers/docker-fpm-frr/staticd.conf.j2 Show resolved Hide resolved
@pavel-shirshov
Copy link
Contributor

Also. If you introduce ip routes to the staticd.conf, should we remove them from zebra.conf?

@shikenghua
Copy link
Contributor Author

yes, you are right. ip routes block should be removed from zebra.conf. Thanks.

@pavel-shirshov
Copy link
Contributor

Can you please remove ip route and ipv6 route from zebra.conf and I'll push this change?

default_route block already moved to staticd.conf.j2
@shikenghua
Copy link
Contributor Author

Done. Please review again.

@lguohan
Copy link
Collaborator

lguohan commented Aug 10, 2019

retest this please

1 similar comment
@pavel-shirshov
Copy link
Contributor

retest this please

Copy link
Contributor

@pavel-shirshov pavel-shirshov left a comment

Choose a reason for hiding this comment

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

Let's wait until the tests are good.

@lguohan
Copy link
Collaborator

lguohan commented Aug 13, 2019

tests are failing, please fix the test.

@shikenghua
Copy link
Contributor Author

Don't understand why the tests fail. What is "Build finished. No test results found" means? I checked other PRs and found that some of them passed with the same "Build finished. No test results found" messages. Maybe I just run the test again.

@shikenghua
Copy link
Contributor Author

retest this please

@pavel-shirshov
Copy link
Contributor

* Add test for staticd.conf.j2 template

* Correct the sample output of zebra.conf.j2 template

* Fix a typo in test_zebra_frr
@lguohan
Copy link
Collaborator

lguohan commented Aug 15, 2019

retest vs please

* Fix test errors in test_j2files.py and test_j2files_t2_chassis_fe.py

* Fix typo in test_j2files_t2_chassis_fe.py
@pavel-shirshov
Copy link
Contributor

retest baseimage please

@pavel-shirshov pavel-shirshov merged commit bf08a2c into sonic-net:master Aug 16, 2019
wangshengjun pushed a commit to wangshengjun/sonic-buildimage that referenced this pull request Nov 16, 2020
…net#3306)

* [docker-fpm-frr]: Generate separated staticd.conf for staticd

Generate staticd.conf by templates/staticd.conf.j2 with config DB data

* [docker-fpm-frr]: Remove default_route block from zebra.conf.j2

default_route block already moved to staticd.conf.j2

* [docker-fpm-frr]: Add test for staticd.conf.j2 template

* Add test for staticd.conf.j2 template

* Correct the sample output of zebra.conf.j2 template

* Fix a typo in test_zebra_frr

* [docker-fpm-frr]: Fix test_j2files test errors

* Fix test errors in test_j2files.py and test_j2files_t2_chassis_fe.py

* Fix typo in test_j2files_t2_chassis_fe.py
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.

3 participants