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

Fix key generation in removeDecapTunnel #2322

Merged
merged 1 commit into from
Jun 13, 2022

Conversation

msosyak
Copy link
Contributor

@msosyak msosyak commented Jun 10, 2022

Signed-off-by: Myron Sosyak myronx.sosyak@intel.com

After the latest changes in this PR #2190 an issue was introduced. When the tunnel was deleted the TunnelTermEntries were deleted from ASIC but not from the OA cache. Due to that then the same tunnel is created the TunnelTermEntries are not created as OA has it in local cache.

What I did
Fix key generation in removeDecapTunnel

Why I did it
To fix the issue described above.

How I verified it
On SONiC testbed after deployment of t1/t0 topology

docker exec -ti swss bash
cp /etc/swss/config.d/ipinip.json deltun.json
sed -i 's/SET/DEL/g' deltun.json
swssconfig deltun.json
swssconfig /etc/swss/config.d/ipinip.json 

Check in logs that entries were removed and then created.

Jun 10 08:45:39.973461 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 192.168.0.1
Jun 10 08:45:39.974420 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 10.1.0.32
Jun 10 08:45:39.975411 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 10.0.0.56
Jun 10 08:45:39.976601 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 10.0.0.58
Jun 10 08:45:39.977533 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 10.0.0.60
Jun 10 08:45:39.978469 igk-6-dut NOTICE swss#orchagent: :- removeDecapTunnelTermEntry: Removed decap tunnel term entry with ip address: 10.0.0.62Jun 10 08:45:55.653637 igk-6-dut NOTICE swss#swssconfig: :- main: Loading config from JSON file:/etc/swss/config.d/ipinip.json...
Jun 10 08:45:55.659735 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnel: Create overlay loopback router interface oid:6000000000740
Jun 10 08:45:55.664682 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 192.168.0.1
Jun 10 08:45:55.667057 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 10.1.0.32
Jun 10 08:45:55.669582 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 10.0.0.56
Jun 10 08:45:55.671794 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 10.0.0.58
Jun 10 08:45:55.673442 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 10.0.0.60
Jun 10 08:45:55.675260 igk-6-dut NOTICE swss#orchagent: :- addDecapTunnelTermEntries: Created tunnel entry for ip: 10.0.0.62

Details if related

Signed-off-by: Myron Sosyak <myronx.sosyak@intel.com>
@msosyak msosyak requested a review from prsunny as a code owner June 10, 2022 09:03
@msosyak
Copy link
Contributor Author

msosyak commented Jun 10, 2022

@bingwang-ms Please review

@prsunny
Copy link
Collaborator

prsunny commented Jun 10, 2022

Please raise a PR for 202012.

@prsunny prsunny merged commit bf4d890 into sonic-net:master Jun 13, 2022
@msosyak
Copy link
Contributor Author

msosyak commented Jun 14, 2022

@prsunny For 202012 the issue was fixed in cherry-pick of original PR which caused this issue. Please look at https://github.com/Azure/sonic-swss/pull/2246/files#diff-2fefef221204491c672d7703f585e9c31751ec198a4c278cb601287936235788R780-R789

@prsunny
Copy link
Collaborator

prsunny commented Jun 14, 2022

@prsunny For 202012 the issue was fixed in cherry-pick of original PR which caused this issue. Please look at https://github.com/Azure/sonic-swss/pull/2246/files#diff-2fefef221204491c672d7703f585e9c31751ec198a4c278cb601287936235788R780-R789

So if it was a cherry-pick, then how did it got missed in master? @bingwang-ms

yxieca pushed a commit that referenced this pull request Jun 20, 2022
*After the latest changes in this PR #2190 an issue was introduced. When the tunnel was deleted the TunnelTermEntries were deleted from ASIC but not from the OA cache. Due to that then the same tunnel is created the TunnelTermEntries are not created as OA has it in local cache.
Signed-off-by: Myron Sosyak <myronx.sosyak@intel.com>
@bingwang-ms
Copy link
Contributor

@prsunny For 202012 the issue was fixed in cherry-pick of original PR which caused this issue. Please look at https://github.com/Azure/sonic-swss/pull/2246/files#diff-2fefef221204491c672d7703f585e9c31751ec198a4c278cb601287936235788R780-R789

So if it was a cherry-pick, then how did it got missed in master? @bingwang-ms

I found the issue when doing the cherry-pick of PR #2190 to 202012 branch. And I fixed the issue when I was addressing the cherry-pick conflict. But I forget to backport the fix to master. Sorry for the trouble. And thanks @msosyak for the fix.

preetham-singh pushed a commit to preetham-singh/sonic-swss that referenced this pull request Aug 6, 2022
*After the latest changes in this PR sonic-net#2190 an issue was introduced. When the tunnel was deleted the TunnelTermEntries were deleted from ASIC but not from the OA cache. Due to that then the same tunnel is created the TunnelTermEntries are not created as OA has it in local cache.
Signed-off-by: Myron Sosyak <myronx.sosyak@intel.com>
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.

4 participants