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

Global and Interface commands for IPv6 Link local address enhancements #1159

Merged
merged 9 commits into from
Aug 18, 2021

Conversation

AkhileshSamineni
Copy link
Contributor

@AkhileshSamineni AkhileshSamineni commented Oct 10, 2020

As per the HLD - sonic-net/SONiC#625 , added config and interface commands.

SONiC CLI per interface configuration command to enable and disable the IPv6 link-local address mode when addresses are not configured manually.

Example:

config interface ipv6 enable use-link-local-only Ethernet24
config interface ipv6 disable use-link-local-only Ethernet24

SONiC CLI global command to enable or disable the IPv6 auto link-local address mode on all eligible interfaces.

config ipv6 enable link-local
config ipv6 disable link-local

Show command to display the link local mode of all interfaces.

root@sonic:/home/admin# show ipv6 link-local-mode 
+------------------+----------+
| Interface Name   | Mode     |
+==================+==========+
| Ethernet16       | Disabled |
+------------------+----------+
| Ethernet18       | Enabled  |
+------------------+----------+
root@sonic:/home/admin# 

Depends on:
sonic-net/sonic-buildimage#5584
sonic-net/sonic-swss#1463

Signed-off-by: Akhilesh Samineni [email protected]

Copy link
Contributor

@lguohan lguohan left a comment

Choose a reason for hiding this comment

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

please add unit tests.

@lguohan lguohan requested a review from prsunny April 14, 2021 21:23
@lgtm-com
Copy link

lgtm-com bot commented Apr 15, 2021

This pull request introduces 1 alert when merging 56f74cd into eba5c04 - view on LGTM.com

new alerts:

  • 1 for Unused local variable

@AkhileshSamineni
Copy link
Contributor Author

please add unit tests.

@lguohan Added unit tests.

@AkhileshSamineni
Copy link
Contributor Author

The failures are not related to the code changes, Please check it.

@AkhileshSamineni
Copy link
Contributor Author

Please re-run the build, as the failures are not related to the code changes.

@anshuv-mfst
Copy link

Hi @prsunny - could you please help with re-run.

@prsunny
Copy link
Contributor

prsunny commented May 5, 2021

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@lguohan
Copy link
Contributor

lguohan commented May 12, 2021

@prsunny to review

@prsunny
Copy link
Contributor

prsunny commented Jun 10, 2021

@venkatmahalingam , could you please review

@AkhileshSamineni
Copy link
Contributor Author

3 vs testcases are failing which are not related to this PR changes.

Copy link
Contributor

@prsunny prsunny left a comment

Choose a reason for hiding this comment

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

please also update command reference guide

config/main.py Show resolved Hide resolved
config/main.py Show resolved Hide resolved
config/main.py Show resolved Hide resolved
config/main.py Show resolved Hide resolved
@AkhileshSamineni
Copy link
Contributor Author

please also update command reference guide

@prsunny Updated.

rlhui pushed a commit to sonic-net/sonic-buildimage that referenced this pull request Jul 20, 2021
As per HLD - sonic-net/SONiC#625

FRR Patches:

0009-Link-local-scope-was-not-set-while-binding-socket-for-bgp-ipv6-link-local-neighbors.patch
Files modified : bgpd_network.c and bgpd/bgp_zebra.c
Fix for : Link local scope was not set while binding socket with local address causing socket errors for bgp ipv6 link local neighbors.

0010-VRF-interface-lookup-was-still-done-in-the-default-vrf.patch
Files modified : staticd/static_zebra.c
Fix for : VRF interface lookup was still done in the default-vrf which was causing the interface lookup to fail. Due to this static-route pointing to link-local was not getting installed.

0011-Changes-to-send-ipv6-link-local-address-as-nexthop-to-fpmsyncd.patch
Files modified : zebra/zebra_fpm_netlink.c
Fix for : Made changes to send ipv6 address as nexthop to fpmsyncd.

Depends on:
sonic-net/sonic-utilities#1159
sonic-net/sonic-swss#1463

Signed-off-by: Akhilesh Samineni [email protected]
@anshuv-mfst
Copy link

Hi @prsunny - could you please help with merge.

@prsunny
Copy link
Contributor

prsunny commented Jul 21, 2021

@lguohan , could you please signoff?

@prsunny
Copy link
Contributor

prsunny commented Jul 31, 2021

@lguohan , reminder

@lguohan , could you please signoff?

Copy link
Contributor

@venkatmahalingam venkatmahalingam left a comment

Choose a reason for hiding this comment

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

I dont think, global implementation is done as per HLD comments (IMO, looping all the available interfaces for global config is a work-around and it doesnt work for any new interfaces after global config), please re-visit.

@AkhileshSamineni
Copy link
Contributor Author

I dont think, global implementation is done as per HLD comments (IMO, looping all the available interfaces for global config is a work-around and it doesnt work for any new interfaces after global config), please re-visit.

@venkatmahalingam
Global field in device_metadata is not planned as part this PR, it should be an future item.

@anshuv-mfst
Copy link

hi @prsunny - could you please review and approve asap, this is needed in 202106 release

@adyeung
Copy link

adyeung commented Aug 5, 2021

@prsunny pls help merge this

@lguohan
Copy link
Contributor

lguohan commented Aug 5, 2021

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@prsunny
Copy link
Contributor

prsunny commented Aug 6, 2021

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@adyeung
Copy link

adyeung commented Aug 6, 2021

@prsunny build test pass, pls help merge

judyjoseph pushed a commit to sonic-net/sonic-buildimage that referenced this pull request Aug 7, 2021
As per HLD - sonic-net/SONiC#625

FRR Patches:

0009-Link-local-scope-was-not-set-while-binding-socket-for-bgp-ipv6-link-local-neighbors.patch
Files modified : bgpd_network.c and bgpd/bgp_zebra.c
Fix for : Link local scope was not set while binding socket with local address causing socket errors for bgp ipv6 link local neighbors.

0010-VRF-interface-lookup-was-still-done-in-the-default-vrf.patch
Files modified : staticd/static_zebra.c
Fix for : VRF interface lookup was still done in the default-vrf which was causing the interface lookup to fail. Due to this static-route pointing to link-local was not getting installed.

0011-Changes-to-send-ipv6-link-local-address-as-nexthop-to-fpmsyncd.patch
Files modified : zebra/zebra_fpm_netlink.c
Fix for : Made changes to send ipv6 address as nexthop to fpmsyncd.

Depends on:
sonic-net/sonic-utilities#1159
sonic-net/sonic-swss#1463

Signed-off-by: Akhilesh Samineni [email protected]
carl-nokia pushed a commit to carl-nokia/sonic-buildimage that referenced this pull request Aug 7, 2021
As per HLD - sonic-net/SONiC#625

FRR Patches:

0009-Link-local-scope-was-not-set-while-binding-socket-for-bgp-ipv6-link-local-neighbors.patch
Files modified : bgpd_network.c and bgpd/bgp_zebra.c
Fix for : Link local scope was not set while binding socket with local address causing socket errors for bgp ipv6 link local neighbors.

0010-VRF-interface-lookup-was-still-done-in-the-default-vrf.patch
Files modified : staticd/static_zebra.c
Fix for : VRF interface lookup was still done in the default-vrf which was causing the interface lookup to fail. Due to this static-route pointing to link-local was not getting installed.

0011-Changes-to-send-ipv6-link-local-address-as-nexthop-to-fpmsyncd.patch
Files modified : zebra/zebra_fpm_netlink.c
Fix for : Made changes to send ipv6 address as nexthop to fpmsyncd.

Depends on:
sonic-net/sonic-utilities#1159
sonic-net/sonic-swss#1463

Signed-off-by: Akhilesh Samineni [email protected]
@adyeung
Copy link

adyeung commented Aug 12, 2021

@lguohan pls help merge

@prsunny prsunny merged commit 29f4a16 into sonic-net:master Aug 18, 2021
judyjoseph pushed a commit that referenced this pull request Aug 20, 2021
#1159)

* Global and Interface commands for IPv6 Link local feature
* SONiC CLI per interface configuration command to enable and disable the IPv6 link-local address mode when addresses are not configured manually.
Signed-off-by: Akhilesh Samineni <[email protected]>
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.

7 participants