Debian Codegraph @

ansible_collections/dellemc/enterprise_sonic/docs/dellemc.enterprise_sonic.sonic_qos_buffer_module.rst

raw
1 .. _dellemc.enterprise_sonic.sonic_qos_buffer_module:
2
3
4 *****************************************
5 dellemc.enterprise_sonic.sonic_qos_buffer
6 *****************************************
7
8 **Manage QoS buffer configuration on SONiC**
9
10
11 Version added: 2.5.0
12
13 .. contents::
14 :local:
15 :depth: 1
16
17
18 Synopsis
19 --------
20 - This module provides configuration management of QoS buffer for devices running SONiC
21
22
23
24
25 Parameters
26 ----------
27
28 .. raw:: html
29
30 <table border=0 cellpadding=0 class="documentation-table">
31 <tr>
32 <th colspan="3">Parameter</th>
33 <th>Choices/<font color="blue">Defaults</font></th>
34 <th width="100%">Comments</th>
35 </tr>
36 <tr>
37 <td colspan="3">
38 <div class="ansibleOptionAnchor" id="parameter-"></div>
39 <b>config</b>
40 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
41 <div style="font-size: small">
42 <span style="color: purple">dictionary</span>
43 </div>
44 </td>
45 <td>
46 </td>
47 <td>
48 <div>QoS buffer configuration</div>
49 </td>
50 </tr>
51 <tr>
52 <td class="elbow-placeholder"></td>
53 <td colspan="2">
54 <div class="ansibleOptionAnchor" id="parameter-"></div>
55 <b>buffer_init</b>
56 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
57 <div style="font-size: small">
58 <span style="color: purple">boolean</span>
59 </div>
60 <div style="font-style: italic; font-size: small; color: darkgreen">added in 3.0.0</div>
61 </td>
62 <td>
63 <ul style="margin: 0; padding: 0"><b>Choices:</b>
64 <li>no</li>
65 <li>yes</li>
66 </ul>
67 </td>
68 <td>
69 <div>Initialize QoS buffer based on system defaults</div>
70 <div>Buffer must be initialized to configure <em>buffer_pools</em> and <em>buffer_profiles</em></div>
71 </td>
72 </tr>
73 <tr>
74 <td class="elbow-placeholder"></td>
75 <td colspan="2">
76 <div class="ansibleOptionAnchor" id="parameter-"></div>
77 <b>buffer_pools</b>
78 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
79 <div style="font-size: small">
80 <span style="color: purple">list</span>
81 / <span style="color: purple">elements=dictionary</span>
82 </div>
83 </td>
84 <td>
85 </td>
86 <td>
87 <div>Buffer pools configuration</div>
88 </td>
89 </tr>
90 <tr>
91 <td class="elbow-placeholder"></td>
92 <td class="elbow-placeholder"></td>
93 <td colspan="1">
94 <div class="ansibleOptionAnchor" id="parameter-"></div>
95 <b>name</b>
96 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
97 <div style="font-size: small">
98 <span style="color: purple">string</span>
99 / <span style="color: red">required</span>
100 </div>
101 </td>
102 <td>
103 <ul style="margin: 0; padding: 0"><b>Choices:</b>
104 <li>ingress_lossless_pool</li>
105 </ul>
106 </td>
107 <td>
108 <div>Name of buffer pool</div>
109 </td>
110 </tr>
111 <tr>
112 <td class="elbow-placeholder"></td>
113 <td class="elbow-placeholder"></td>
114 <td colspan="1">
115 <div class="ansibleOptionAnchor" id="parameter-"></div>
116 <b>xoff</b>
117 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
118 <div style="font-size: small">
119 <span style="color: purple">integer</span>
120 </div>
121 </td>
122 <td>
123 </td>
124 <td>
125 <div>Amount of shared buffer space in bytes, must be less than pool size</div>
126 <div>Required non-key attribute</div>
127 </td>
128 </tr>
129
130 <tr>
131 <td class="elbow-placeholder"></td>
132 <td colspan="2">
133 <div class="ansibleOptionAnchor" id="parameter-"></div>
134 <b>buffer_profiles</b>
135 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
136 <div style="font-size: small">
137 <span style="color: purple">list</span>
138 / <span style="color: purple">elements=dictionary</span>
139 </div>
140 </td>
141 <td>
142 </td>
143 <td>
144 <div>Buffer profiles configuration</div>
145 <div><em>static_threshold</em> and <em>dynamic_threshold</em> are mutually exclusive required non-key attributes</div>
146 </td>
147 </tr>
148 <tr>
149 <td class="elbow-placeholder"></td>
150 <td class="elbow-placeholder"></td>
151 <td colspan="1">
152 <div class="ansibleOptionAnchor" id="parameter-"></div>
153 <b>dynamic_threshold</b>
154 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
155 <div style="font-size: small">
156 <span style="color: purple">integer</span>
157 </div>
158 </td>
159 <td>
160 </td>
161 <td>
162 <div>Dynamic threshold value</div>
163 <div>Range -6-3</div>
164 </td>
165 </tr>
166 <tr>
167 <td class="elbow-placeholder"></td>
168 <td class="elbow-placeholder"></td>
169 <td colspan="1">
170 <div class="ansibleOptionAnchor" id="parameter-"></div>
171 <b>name</b>
172 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
173 <div style="font-size: small">
174 <span style="color: purple">string</span>
175 / <span style="color: red">required</span>
176 </div>
177 </td>
178 <td>
179 </td>
180 <td>
181 <div>Name of buffer profile</div>
182 </td>
183 </tr>
184 <tr>
185 <td class="elbow-placeholder"></td>
186 <td class="elbow-placeholder"></td>
187 <td colspan="1">
188 <div class="ansibleOptionAnchor" id="parameter-"></div>
189 <b>pause_threshold</b>
190 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
191 <div style="font-size: small">
192 <span style="color: purple">integer</span>
193 </div>
194 </td>
195 <td>
196 </td>
197 <td>
198 <div>Threshold value at which to stop traffic from peer</div>
199 <div>Range 46080-8388608</div>
200 <div>Configurable for ingress lossless pool</div>
201 </td>
202 </tr>
203 <tr>
204 <td class="elbow-placeholder"></td>
205 <td class="elbow-placeholder"></td>
206 <td colspan="1">
207 <div class="ansibleOptionAnchor" id="parameter-"></div>
208 <b>pool</b>
209 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
210 <div style="font-size: small">
211 <span style="color: purple">string</span>
212 </div>
213 </td>
214 <td>
215 <ul style="margin: 0; padding: 0"><b>Choices:</b>
216 <li>ingress_lossless_pool</li>
217 <li>egress_lossless_pool</li>
218 <li>egress_lossy_pool</li>
219 </ul>
220 </td>
221 <td>
222 <div>Name of buffer pool</div>
223 <div>Required non-key attribute</div>
224 </td>
225 </tr>
226 <tr>
227 <td class="elbow-placeholder"></td>
228 <td class="elbow-placeholder"></td>
229 <td colspan="1">
230 <div class="ansibleOptionAnchor" id="parameter-"></div>
231 <b>size</b>
232 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
233 <div style="font-size: small">
234 <span style="color: purple">integer</span>
235 </div>
236 </td>
237 <td>
238 </td>
239 <td>
240 <div>Size of reserved buffer in bytes</div>
241 <div>Required non-key attribute</div>
242 </td>
243 </tr>
244 <tr>
245 <td class="elbow-placeholder"></td>
246 <td class="elbow-placeholder"></td>
247 <td colspan="1">
248 <div class="ansibleOptionAnchor" id="parameter-"></div>
249 <b>static_threshold</b>
250 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
251 <div style="font-size: small">
252 <span style="color: purple">integer</span>
253 </div>
254 </td>
255 <td>
256 </td>
257 <td>
258 <div>Static threshold for the shared usage in bytes</div>
259 </td>
260 </tr>
261
262
263 <tr>
264 <td colspan="3">
265 <div class="ansibleOptionAnchor" id="parameter-"></div>
266 <b>state</b>
267 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
268 <div style="font-size: small">
269 <span style="color: purple">string</span>
270 </div>
271 </td>
272 <td>
273 <ul style="margin: 0; padding: 0"><b>Choices:</b>
274 <li><div style="color: blue"><b>merged</b>&nbsp;&larr;</div></li>
275 <li>deleted</li>
276 </ul>
277 </td>
278 <td>
279 <div>The state of the configuration after module completion</div>
280 <div>Replaced and overridden states are not supported for this module due to configuration constraints</div>
281 </td>
282 </tr>
283 </table>
284 <br/>
285
286
287 Notes
288 -----
289
290 .. note::
291 - Tested against Enterprise SONiC Distribution by Dell Technologies.
292 - Supports ``check_mode``.
293
294
295
296 Examples
297 --------
298
299 .. code-block:: yaml
300
301 # Using "merged" state
302 #
303 # Before state:
304 # -------------
305 #
306 # sonic# show running-configuration | grep buffer
307 # buffer init lossless
308 # buffer pool ingress_lossless_pool shared-headroom-size 1000000
309
310 - name: Merge QoS buffer configuration
311 dellemc.enterprise_sonic.sonic_qos_buffer:
312 config:
313 buffer_init: true
314 buffer_pools:
315 - name: ingress_lossless_pool
316 xoff: 3500000
317 buffer_profiles:
318 - name: profile1
319 pool: ingress_lossless_pool
320 size: 45
321 static_threshold: 25
322 pause_threshold: 55000
323 - name: profile2
324 pool: egress_lossless_pool
325 size: 85
326 dynamic_threshold: -2
327 - name: profile3
328 pool: egress_lossy_pool
329 size: 90
330 static_threshold: 30
331 state: merged
332
333 # After state:
334 # ------------
335 #
336 # sonic# show running-configuration | grep buffer
337 # buffer init lossless
338 # buffer pool ingress_lossless_pool shared-headroom-size 3500000
339 # buffer profile profile1 ingress_lossless_pool 45 static-threshold 25 pause pause-threshold 55000
340 # buffer profile profile2 egress_lossy_pool 85 dynamic-threshold -2
341 # buffer profile profile3 egress_lossless_pool 90 static-threshold 30
342 #
343 #
344 # Using "deleted" state
345 #
346 # Before state:
347 # -------------
348 #
349 # sonic# show running-configuration | grep buffer
350 # buffer init lossless
351 # buffer pool ingress_lossless_pool shared-headroom-size 3500000
352 # buffer profile profile1 ingress_lossless_pool 45 static-threshold 25 pause pause-threshold 55000
353 # buffer profile profile2 egress_lossy_pool 85 dynamic-threshold -2
354 # buffer profile profile3 egress_lossless_pool 90 static-threshold 30
355
356 - name: Delete QoS buffer profile configuration
357 dellemc.enterprise_sonic.sonic_qos_buffer:
358 config:
359 buffer_profiles:
360 - name: profile1
361 static_threshold: 25
362 pause_threshold: 55000
363 - name: profile2
364 dynamic_threshold: -2
365 - name: profile3
366 state: deleted
367
368 # After state:
369 # ------------
370 #
371 # sonic# show running-configuration | grep buffer
372 # buffer init lossless
373 # buffer pool ingress_lossless_pool shared-headroom-size 3500000
374 # buffer profile profile1 ingress_lossless_pool 45
375 # buffer profile profile2 egress_lossy_pool 85
376
377
378
379 Return Values
380 -------------
381 Common return values are documented `here <https://docs.ansible.com/projects/ansible/latest/reference_appendices/common_return_values.html#common-return-values>`_, the following are the fields unique to this module:
382
383 .. raw:: html
384
385 <table border=0 cellpadding=0 class="documentation-table">
386 <tr>
387 <th colspan="1">Key</th>
388 <th>Returned</th>
389 <th width="100%">Description</th>
390 </tr>
391 <tr>
392 <td colspan="1">
393 <div class="ansibleOptionAnchor" id="return-"></div>
394 <b>after</b>
395 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
396 <div style="font-size: small">
397 <span style="color: purple">list</span>
398 </div>
399 </td>
400 <td>when changed</td>
401 <td>
402 <div>The resulting configuration model invocation.</div>
403 <br/>
404 <div style="font-size: smaller"><b>Sample:</b></div>
405 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">The configuration returned will always be in the same format of the parameters above.</div>
406 </td>
407 </tr>
408 <tr>
409 <td colspan="1">
410 <div class="ansibleOptionAnchor" id="return-"></div>
411 <b>after_generated</b>
412 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
413 <div style="font-size: small">
414 <span style="color: purple">list</span>
415 </div>
416 </td>
417 <td>when <code>check_mode</code></td>
418 <td>
419 <div>The generated configuration model invocation.</div>
420 <br/>
421 <div style="font-size: smaller"><b>Sample:</b></div>
422 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">The configuration returned will always be in the same format
423 of the parameters above.</div>
424 </td>
425 </tr>
426 <tr>
427 <td colspan="1">
428 <div class="ansibleOptionAnchor" id="return-"></div>
429 <b>before</b>
430 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
431 <div style="font-size: small">
432 <span style="color: purple">list</span>
433 </div>
434 </td>
435 <td>always</td>
436 <td>
437 <div>The configuration prior to the model invocation.</div>
438 <br/>
439 <div style="font-size: smaller"><b>Sample:</b></div>
440 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">The configuration returned will always be in the same format of the parameters above.</div>
441 </td>
442 </tr>
443 <tr>
444 <td colspan="1">
445 <div class="ansibleOptionAnchor" id="return-"></div>
446 <b>commands</b>
447 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
448 <div style="font-size: small">
449 <span style="color: purple">list</span>
450 </div>
451 </td>
452 <td>always</td>
453 <td>
454 <div>The set of commands pushed to the remote device.</div>
455 <br/>
456 <div style="font-size: smaller"><b>Sample:</b></div>
457 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">[&#x27;command 1&#x27;, &#x27;command 2&#x27;, &#x27;command 3&#x27;]</div>
458 </td>
459 </tr>
460 </table>
461 <br/><br/>
462
463
464 Status
465 ------
466
467
468 Authors
469 ~~~~~~~
470
471 - S\. Talabi (@stalabi1)