Skip gathering dualtor facts on single tor testbed#2646
Skip gathering dualtor facts on single tor testbed#2646bingwang-ms merged 1 commit intosonic-net:masterfrom
Conversation
I noticed that the dual_tor_facts plugin costs around 5 minutes to generate dualtor facts when deploying or generating minigraph. The generated dualtor facts is not used on single tor testbed though. This commit updates the task file for deploying minigraph to skip dual_tor_facts plugin on single tor testbed. Signed-off-by: bingwang <[email protected]>
| - name: set default dualtor facts | ||
| set_fact: | ||
| dual_tor_facts: {} | ||
| when: "'dualtor' not in topo" |
There was a problem hiding this comment.
Should it be like below?
when: "{{'dualtor' not in topo }}"
There was a problem hiding this comment.
I think it OK to omit the {{ }} because it's not a template. And i verified it by deploying a minigraph.
There was a problem hiding this comment.
Please ignore this. I tested your code, it works. On the contrary, ansible complains with warning [WARNING]: conditional statements should not include jinja2 templating delimiters such as {{ }} or {% %}. Found: {{ 'dualtor' in topo }} if format when: "{{'dualtor' not in topo }}" is used.
theasianpianist
left a comment
There was a problem hiding this comment.
I find it interesting that the dual_tor_facts takes so long for you, it ran in a few seconds for me originally. I'll look into improving performance at some point.
|
What was the time difference on 7260 before/after? |
The plugin will take a long time if we add multiple inventory files (such as str and veos). At such case, the |
I noticed that the dual_tor_facts plugin costs around 5 minutes to generate dualtor facts when deploying or generating minigraph. The generated dualtor facts is not used on single tor testbed though. This commit updates the task file for deploying minigraph to skip dual_tor_facts plugin on single tor testbed. Signed-off-by: bingwang <[email protected]>
Why I did it submodule advance b085b5f - [ci] Fix pipeline error about team5 not found. (Core dump in orchagent when assigning router interface to a vlan with untagged mode sonic-net#2684) (3 hours ago) [Liu Shilong] 4549b4c - Fix issue: there is no retry while creating a RIF which is in removing state ([201811 sub-module] advance sub-modules: utilities, swss, swss-common sonic-net#2679) (3 hours ago) [Junchao-Mellanox] 980a45b - [FDB]Fixing FDB consolidated flush for Remote MACs (pmon to stretch sonic-net#2673) (3 hours ago) [Sudharsan Dhamal Gopalarathnam] c646607 - Do not allow to add port to .1Q bridge while router port deletion is not completed (Update SDK, FW and SAI sonic-net#2669) (3 hours ago) [Lior Avramov] 4a321f0 - [orchagent]: Get bridge port ID from orchagent cache instead of SAI API ([201811 sub module] advance sairedis sub module sonic-net#2657) (3 hours ago) [Lawrence Lee] f4b88f3 - [Dual-ToR] handle 'mux_tunnel_egress_acl' attrib in order to change ACL configuration (drop on ingress/egress) on standby ToR (lm75 doesn't support written alarm to syslog. sonic-net#2646) (3 hours ago) [Andriy Yurkiv] a4f29c1 - [Workaround] EvpnRemoteVnip2pOrch warmboot check failure ([teamd]: wait for swss db flush done before starting teamd container sonic-net#2626) (3 hours ago) [jcaiMR] 53ee0a8 - Support for tc-dot1p and tc-dscp qosmap ([201803] [router-advertiser] Add templated script to wait for pertinent interfaces to be ready before starting radvd sonic-net#2559) (3 hours ago) [Divya Mukundan] b953866 - [dual-tor] add missing SAI attribte in order to create IPNIP tunnel (Config reload/load_minigraph not clearing State DB sonic-net#2503) (3 hours ago) [Andriy Yurkiv] How I did it How to verify it
Signed-off-by: bingwang [email protected]
Description of PR
Summary:
Fixes # (issue)
I noticed that the
dual_tor_factsplugin costs around 5 minutes to gather dualtor facts when deploying or generating minigraph. The generated dualtor facts is not used on single tor testbed though.This commit updates the task file for deploying minigraph to skip dual_tor_facts plugin on single tor testbed.
Type of change
Approach
What is the motivation for this PR?
This PR is to updates
ansible/config_sonic_basedon_testbed.ymlto skipdual_tor_factsplugin on single tor testbed.How did you do it?
Add a condition check for
dual_tor_factstasks.How did you verify/test it?
Verified by deploying minigraph on Arista7260. The task finished without exception, and the generated minigraph files are exactly the same.
Any platform specific information?
No.
Supported testbed topology if it's a new test case?
No.
Documentation