Skip to content

Commit 2037658

Browse files
samaityzhenggen-xu
authored andcommitted
DPB Breakout Cli Test with proper setup (#18)
* DPB Breakout Cli Test with proper setup Signed-off-by: Sangita Maity <sangitamaity0211@gmail.com> * Adding more Test cases Signed-off-by: Sangita Maity <sangitamaity0211@gmail.com>
1 parent 1ba3090 commit 2037658

File tree

4 files changed

+591
-2
lines changed

4 files changed

+591
-2
lines changed

platform/vs/docker-sonic-vs/Dockerfile.j2

+4-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ RUN apt-get install -y net-tools \
4141
libpython2.7 \
4242
grub2-common \
4343
python-click-default-group \
44-
python-click \
4544
python-natsort \
4645
python-tabulate \
4746
bash-completion \
@@ -51,13 +50,15 @@ RUN apt-get install -y net-tools \
5150
apt-utils \
5251
psmisc \
5352
tcpdump \
54-
python-scapy
53+
python-scapy \
54+
jq
5555

5656
RUN pip install setuptools
5757
RUN pip install py2_ipaddress
5858
RUN pip install six
5959
RUN pip install pyroute2==0.5.3 netifaces==0.10.7
6060
RUN pip install monotonic==1.5
61+
RUN pip install click==7.0.0
6162

6263
{% if docker_sonic_vs_debs.strip() -%}
6364
# Copy locally-built Debian package dependencies
@@ -107,6 +108,7 @@ COPY ["files/arp_update", "/usr/bin/"]
107108
COPY ["files/buffers_config.j2", "files/qos_config.j2", "/usr/share/sonic/templates/"]
108109
COPY ["files/sonic_version.yml", "/etc/sonic/"]
109110
COPY ["database_config.json", "/etc/default/sonic-db/"]
111+
COPY ["platform.json", "/usr/share/sonic/device/x86_64-kvm_x86_64-r0/Force10-S6000/"]
110112

111113
# Workaround the tcpdump issue
112114
RUN mv /usr/sbin/tcpdump /usr/bin/tcpdump
+226
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,226 @@
1+
{
2+
"Ethernet0": {
3+
"index": "0,0,0,0",
4+
"lanes": "25,26,27,28",
5+
"alias_at_lanes": "Eth0/1,Eth0/2,Eth0/3,Eth0/4",
6+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
7+
"default_brkout_mode": "1x100G[40G]"
8+
},
9+
"Ethernet4": {
10+
"index": "1,1,1,1",
11+
"lanes": "29,30,31,32",
12+
"alias_at_lanes": "Eth1/1,Eth1/2,Eth1/3,Eth1/4",
13+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G]",
14+
"default_brkout_mode": "1x100G[40G]"
15+
},
16+
"Ethernet8": {
17+
"index": "2,2,2,2",
18+
"lanes": "33,34,35,36",
19+
"alias_at_lanes": "Eth2/1,Eth2/2,Eth2/3,Eth2/4",
20+
"breakout_modes": "1x100G[40G],2x50G,2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
21+
"default_brkout_mode": "1x100G[40G]"
22+
},
23+
"Ethernet12": {
24+
"index": "3,3,3,3",
25+
"lanes": "37,38,39,40",
26+
"alias_at_lanes": "Eth3/1,Eth3/2,Eth3/3,Eth3/4",
27+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
28+
"default_brkout_mode": "1x100G[40G]"
29+
},
30+
"Ethernet16": {
31+
"index": "4,4,4,4",
32+
"lanes": "45,46,47,48",
33+
"alias_at_lanes": "Eth4/1,Eth4/2,Eth4/3,Eth4/4",
34+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
35+
"default_brkout_mode": "1x100G[40G]"
36+
},
37+
"Ethernet20": {
38+
"index": "5,5,5,5",
39+
"lanes": "41,42,43,44",
40+
"alias_at_lanes": "Eth5/1,Eth5/2,Eth5/3,Eth5/4",
41+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
42+
"default_brkout_mode": "1x100G[40G]"
43+
},
44+
"Ethernet24": {
45+
"index": "6,6,6,6",
46+
"lanes": "1,2,3,4",
47+
"alias_at_lanes": "Eth6/1,Eth6/2,Eth6/3,Eth6/4",
48+
"breakout_modes": "1x100G[40G],4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
49+
"default_brkout_mode": "1x100G[40G]"
50+
},
51+
"Ethernet28": {
52+
"index": "7,7,7,7",
53+
"lanes": "5,6,7,8",
54+
"alias_at_lanes": "Eth7/1,Eth7/2,Eth7/3,Eth7/4",
55+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
56+
"default_brkout_mode": "1x100G[40G]"
57+
},
58+
"Ethernet32": {
59+
"index": "8,8,8,8",
60+
"lanes": "13,14,15,16",
61+
"alias_at_lanes": "Eth8/1,Eth8/2,Eth8/3,Eth8/4",
62+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
63+
"default_brkout_mode": "1x100G[40G]"
64+
},
65+
"Ethernet36": {
66+
"index": "9,9,9,9",
67+
"lanes": "9,10,11,12",
68+
"alias_at_lanes": "Eth9/1,Eth9/2,Eth9/3,Eth9/4",
69+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
70+
"default_brkout_mode": "1x100G[40G]"
71+
},
72+
"Ethernet40": {
73+
"index": "10,10,10,10",
74+
"lanes": "17,18,19,20",
75+
"alias_at_lanes": "Eth10/1,Eth10/2,Eth10/3,Eth10/4",
76+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
77+
"default_brkout_mode": "1x100G[40G]"
78+
},
79+
"Ethernet44": {
80+
"index": "11,11,11,11",
81+
"lanes": "21,22,23,24",
82+
"alias_at_lanes": "Eth11/1,Eth11/2,Eth11/3,Eth11/4",
83+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
84+
"default_brkout_mode": "1x100G[40G]"
85+
},
86+
"Ethernet48": {
87+
"index": "12,12,12,12",
88+
"lanes": "53,54,55,56",
89+
"alias_at_lanes": "Eth12/1,Eth12/2,Eth12/3,Eth12/4",
90+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
91+
"default_brkout_mode": "1x100G[40G]"
92+
},
93+
"Ethernet52": {
94+
"index": "13,13,13,13",
95+
"lanes": "49,50,51,52",
96+
"alias_at_lanes": "Eth13/1,Eth13/2,Eth13/3,Eth13/4",
97+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
98+
"default_brkout_mode": "1x100G[40G]"
99+
},
100+
"Ethernet56": {
101+
"index": "14,14,14,14",
102+
"lanes": "57,58,59,60",
103+
"alias_at_lanes": "Eth14/1,Eth14/2,Eth14/3,Eth14/4",
104+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
105+
"default_brkout_mode": "1x100G[40G]"
106+
},
107+
"Ethernet60": {
108+
"index": "15,15,15,15",
109+
"lanes": "61,62,63,64",
110+
"alias_at_lanes": "Eth15/1,Eth15/2,Eth15/3,Eth15/4",
111+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
112+
"default_brkout_mode": "1x100G[40G]"
113+
},
114+
"Ethernet64": {
115+
"index": "16,16,16,16",
116+
"lanes": "69,70,71,72",
117+
"alias_at_lanes": "Eth16/1,Eth16/2,Eth16/3,Eth16/4",
118+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
119+
"default_brkout_mode": "1x100G[40G]"
120+
},
121+
"Ethernet68": {
122+
"index": "17,17,17,17",
123+
"lanes": "65,66,67,68",
124+
"alias_at_lanes": "Eth17/1,Eth17/2,Eth17/3,Eth17/4",
125+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
126+
"default_brkout_mode": "1x100G[40G]"
127+
},
128+
"Ethernet72": {
129+
"index": "18,18,18,18",
130+
"lanes": "73,74,75,76",
131+
"alias_at_lanes": "Eth18/1,Eth18/2,Eth18/3,Eth18/4",
132+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
133+
"default_brkout_mode": "1x100G[40G]"
134+
},
135+
"Ethernet76": {
136+
"index": "19,19,19,19",
137+
"lanes": "77,78,79,80",
138+
"alias_at_lanes": "Eth19/1,Eth19/2,Eth19/3,Eth19/4",
139+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
140+
"default_brkout_mode": "1x100G[40G]"
141+
},
142+
"Ethernet80": {
143+
"index": "20,20,20,20",
144+
"lanes": "109,110,111,112",
145+
"alias_at_lanes": "Eth20/1,Eth20/2,Eth20/3,Eth20/4",
146+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
147+
"default_brkout_mode": "1x100G[40G]"
148+
},
149+
"Ethernet84": {
150+
"index": "21,21,21,21",
151+
"lanes": "105,106,107,108",
152+
"alias_at_lanes": "Eth21/1,Eth21/2,Eth21/3,Eth21/4",
153+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
154+
"default_brkout_mode": "1x100G[40G]"
155+
},
156+
"Ethernet88": {
157+
"index": "22,22,22,22",
158+
"lanes": "113,114,115,116",
159+
"alias_at_lanes": "Eth22/1,Eth22/2,Eth22/3,Eth22/4",
160+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
161+
"default_brkout_mode": "1x100G[40G]"
162+
},
163+
"Ethernet92": {
164+
"index": "23,23,23,23",
165+
"lanes": "117,118,119,120",
166+
"alias_at_lanes": "Eth23/1,Eth23/2,Eth23/3,Eth23/4",
167+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
168+
"default_brkout_mode": "1x100G[40G]"
169+
},
170+
"Ethernet96": {
171+
"index": "24,24,24,24",
172+
"lanes": "125,126,127,128",
173+
"alias_at_lanes": "Eth24/1,Eth24/2,Eth24/3,Eth24/4",
174+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
175+
"default_brkout_mode": "1x100G[40G]"
176+
},
177+
"Ethernet100": {
178+
"index": "25,25,25,25",
179+
"lanes": "121,122,123,124",
180+
"alias_at_lanes": "Eth25/1,Eth25/2,Eth25/3,Eth25/4",
181+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
182+
"default_brkout_mode": "1x100G[40G]"
183+
},
184+
"Ethernet104": {
185+
"index": "26,26,26,26",
186+
"lanes": "81,82,83,84",
187+
"alias_at_lanes": "Eth26/1,Eth26/2,Eth26/3,Eth26/4",
188+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
189+
"default_brkout_mode": "1x100G[40G]"
190+
},
191+
"Ethernet108": {
192+
"index": "27,27,27,27",
193+
"lanes": "85,86,87,88",
194+
"alias_at_lanes": "Eth27/1,Eth27/2,Eth27/3,Eth27/4",
195+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
196+
"default_brkout_mode": "1x100G[40G]"
197+
},
198+
"Ethernet112": {
199+
"index": "28,28,28,28",
200+
"lanes": "93,94,95,96",
201+
"alias_at_lanes": "Eth28/1,Eth28/2,Eth28/3,Eth28/4",
202+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
203+
"default_brkout_mode": "1x100G[40G]"
204+
},
205+
"Ethernet116": {
206+
"index": "29,29,29,29",
207+
"lanes": "89,90,91,92",
208+
"alias_at_lanes": "Eth29/1,Eth29/2,Eth29/3,Eth29/4",
209+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
210+
"default_brkout_mode": "1x100G[40G]"
211+
},
212+
"Ethernet120": {
213+
"index": "30,30,30,30",
214+
"lanes": "101,102,103,104",
215+
"alias_at_lanes": "Eth30/1,Eth30/2,Eth30/3,Eth30/4",
216+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
217+
"default_brkout_mode": "1x100G[40G]"
218+
},
219+
"Ethernet124": {
220+
"index": "31,31,31,31",
221+
"lanes": "97,98,99,100",
222+
"alias_at_lanes": "Eth31/1,Eth31/2,Eth31/3,Eth31/4",
223+
"breakout_modes": "1x100G[40G],2x50G,4x25G[10G],2x25G(2)+1x50G(2),1x50G(2)+2x25G(2)",
224+
"default_brkout_mode": "1x100G[40G]"
225+
}
226+
}

0 commit comments

Comments
 (0)