Debian Codegraph @

ansible_collections/dellemc/enterprise_sonic/docs/dellemc.enterprise_sonic.sonic_interfaces_module.rst

raw
1 .. _dellemc.enterprise_sonic.sonic_interfaces_module:
2
3
4 *****************************************
5 dellemc.enterprise_sonic.sonic_interfaces
6 *****************************************
7
8 **Configure Interface attributes on interfaces such as, Eth, LAG, VLAN, and loopback. (create a loopback interface if it does not exist.)**
9
10
11 Version added: 1.0.0
12
13 .. contents::
14 :local:
15 :depth: 1
16
17
18 Synopsis
19 --------
20 - Configure Interface attributes such as, MTU, admin statu, and so on, on interfaces such as, Eth, LAG, VLAN, and loopback. (create a loopback interface if it does not exist.)
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="2">Parameter</th>
33 <th>Choices/<font color="blue">Defaults</font></th>
34 <th width="100%">Comments</th>
35 </tr>
36 <tr>
37 <td colspan="2">
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">list</span>
43 / <span style="color: purple">elements=dictionary</span>
44 </div>
45 </td>
46 <td>
47 </td>
48 <td>
49 <div>A list of interface configurations.</div>
50 </td>
51 </tr>
52 <tr>
53 <td class="elbow-placeholder"></td>
54 <td colspan="1">
55 <div class="ansibleOptionAnchor" id="parameter-"></div>
56 <b>advertised_speed</b>
57 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
58 <div style="font-size: small">
59 <span style="color: purple">list</span>
60 / <span style="color: purple">elements=string</span>
61 </div>
62 </td>
63 <td>
64 </td>
65 <td>
66 <div>Advertised speeds of the interface.</div>
67 <div>Applicable only for Ethernet interfaces.</div>
68 <div>Supported speeds are dependent on the type of switch.</div>
69 <div>Speeds may be 10, 100, 1000, 2500, 5000, 10000, 20000, 25000, 40000, 50000, 100000, 400000 or 800000.</div>
70 </td>
71 </tr>
72 <tr>
73 <td class="elbow-placeholder"></td>
74 <td colspan="1">
75 <div class="ansibleOptionAnchor" id="parameter-"></div>
76 <b>auto_negotiate</b>
77 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
78 <div style="font-size: small">
79 <span style="color: purple">boolean</span>
80 </div>
81 </td>
82 <td>
83 <ul style="margin: 0; padding: 0"><b>Choices:</b>
84 <li>no</li>
85 <li>yes</li>
86 </ul>
87 </td>
88 <td>
89 <div>auto-negotiate transmission parameters with peer interface.</div>
90 <div>Applicable only for Ethernet interfaces.</div>
91 </td>
92 </tr>
93 <tr>
94 <td class="elbow-placeholder"></td>
95 <td colspan="1">
96 <div class="ansibleOptionAnchor" id="parameter-"></div>
97 <b>autoneg_mode</b>
98 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
99 <div style="font-size: small">
100 <span style="color: purple">string</span>
101 </div>
102 <div style="font-style: italic; font-size: small; color: darkgreen">added in 4.0.0</div>
103 </td>
104 <td>
105 <ul style="margin: 0; padding: 0"><b>Choices:</b>
106 <li>AUTONEG_MODE_BAM</li>
107 <li>AUTONEG_MODE_MSA</li>
108 </ul>
109 </td>
110 <td>
111 <div>BAM/MSA configuration for autonegotiation</div>
112 <div>Applicable only for Ethernet interfaces.</div>
113 <div>auto_negotiate should be set to true to configure autoneg_mode</div>
114 <div>with auto_negotiate set to true , autoneg_mode defaults to BAM</div>
115 </td>
116 </tr>
117 <tr>
118 <td class="elbow-placeholder"></td>
119 <td colspan="1">
120 <div class="ansibleOptionAnchor" id="parameter-"></div>
121 <b>description</b>
122 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
123 <div style="font-size: small">
124 <span style="color: purple">string</span>
125 </div>
126 </td>
127 <td>
128 </td>
129 <td>
130 <div>Description about the interface.</div>
131 </td>
132 </tr>
133 <tr>
134 <td class="elbow-placeholder"></td>
135 <td colspan="1">
136 <div class="ansibleOptionAnchor" id="parameter-"></div>
137 <b>enabled</b>
138 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
139 <div style="font-size: small">
140 <span style="color: purple">boolean</span>
141 </div>
142 </td>
143 <td>
144 <ul style="margin: 0; padding: 0"><b>Choices:</b>
145 <li>no</li>
146 <li>yes</li>
147 </ul>
148 </td>
149 <td>
150 <div>Administrative state of the interface.</div>
151 </td>
152 </tr>
153 <tr>
154 <td class="elbow-placeholder"></td>
155 <td colspan="1">
156 <div class="ansibleOptionAnchor" id="parameter-"></div>
157 <b>fec</b>
158 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
159 <div style="font-size: small">
160 <span style="color: purple">string</span>
161 </div>
162 </td>
163 <td>
164 <ul style="margin: 0; padding: 0"><b>Choices:</b>
165 <li>FEC_RS</li>
166 <li>FEC_FC</li>
167 <li>FEC_DISABLED</li>
168 <li>FEC_DEFAULT</li>
169 <li>FEC_AUTO</li>
170 </ul>
171 </td>
172 <td>
173 <div>Interface FEC (Forward Error Correction).</div>
174 <div>Applicable only for Ethernet interfaces.</div>
175 </td>
176 </tr>
177 <tr>
178 <td class="elbow-placeholder"></td>
179 <td colspan="1">
180 <div class="ansibleOptionAnchor" id="parameter-"></div>
181 <b>mtu</b>
182 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
183 <div style="font-size: small">
184 <span style="color: purple">integer</span>
185 </div>
186 </td>
187 <td>
188 </td>
189 <td>
190 <div>MTU of the interface.</div>
191 <div>Not applicable for Loopback interfaces.</div>
192 </td>
193 </tr>
194 <tr>
195 <td class="elbow-placeholder"></td>
196 <td colspan="1">
197 <div class="ansibleOptionAnchor" id="parameter-"></div>
198 <b>name</b>
199 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
200 <div style="font-size: small">
201 <span style="color: purple">string</span>
202 / <span style="color: red">required</span>
203 </div>
204 </td>
205 <td>
206 </td>
207 <td>
208 <div>The name of the interface, for example, &#x27;Eth1/15&#x27;.</div>
209 </td>
210 </tr>
211 <tr>
212 <td class="elbow-placeholder"></td>
213 <td colspan="1">
214 <div class="ansibleOptionAnchor" id="parameter-"></div>
215 <b>speed</b>
216 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
217 <div style="font-size: small">
218 <span style="color: purple">string</span>
219 </div>
220 </td>
221 <td>
222 <ul style="margin: 0; padding: 0"><b>Choices:</b>
223 <li>SPEED_10MB</li>
224 <li>SPEED_100MB</li>
225 <li>SPEED_1GB</li>
226 <li>SPEED_2500MB</li>
227 <li>SPEED_5GB</li>
228 <li>SPEED_10GB</li>
229 <li>SPEED_20GB</li>
230 <li>SPEED_25GB</li>
231 <li>SPEED_40GB</li>
232 <li>SPEED_50GB</li>
233 <li>SPEED_100GB</li>
234 <li>SPEED_200GB</li>
235 <li>SPEED_400GB</li>
236 <li>SPEED_800GB</li>
237 </ul>
238 </td>
239 <td>
240 <div>Interface speed.</div>
241 <div>Applicable only for Ethernet interfaces.</div>
242 <div>Supported speeds are dependent on the type of switch.</div>
243 </td>
244 </tr>
245 <tr>
246 <td class="elbow-placeholder"></td>
247 <td colspan="1">
248 <div class="ansibleOptionAnchor" id="parameter-"></div>
249 <b>unreliable_los</b>
250 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
251 <div style="font-size: small">
252 <span style="color: purple">string</span>
253 </div>
254 </td>
255 <td>
256 <ul style="margin: 0; padding: 0"><b>Choices:</b>
257 <li>UNRELIABLE_LOS_MODE_ON</li>
258 <li>UNRELIABLE_LOS_MODE_OFF</li>
259 <li>UNRELIABLE_LOS_MODE_AUTO</li>
260 </ul>
261 </td>
262 <td>
263 <div>Monitoring type to be used for generating a loss of service alarm.</div>
264 </td>
265 </tr>
266
267 <tr>
268 <td colspan="2">
269 <div class="ansibleOptionAnchor" id="parameter-"></div>
270 <b>state</b>
271 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
272 <div style="font-size: small">
273 <span style="color: purple">string</span>
274 </div>
275 </td>
276 <td>
277 <ul style="margin: 0; padding: 0"><b>Choices:</b>
278 <li><div style="color: blue"><b>merged</b>&nbsp;&larr;</div></li>
279 <li>replaced</li>
280 <li>overridden</li>
281 <li>deleted</li>
282 </ul>
283 </td>
284 <td>
285 <div>The state the configuration should be left in.</div>
286 </td>
287 </tr>
288 </table>
289 <br/>
290
291
292 Notes
293 -----
294
295 .. note::
296 - Tested against Enterprise SONiC Distribution by Dell Technologies.
297 - Supports ``check_mode``.
298
299
300
301 Examples
302 --------
303
304 .. code-block:: yaml
305
306 # Using "deleted" state
307 #
308 # Before state:
309 # -------------
310 #
311 # show interface status | no-more
312 # ------------------------------------------------------------------------------------------
313 # Name Description Admin Oper AutoNeg Speed MTU
314 # ------------------------------------------------------------------------------------------
315 # Ethernet0 - up 100000 9100
316 # Ethernet4 - up 100000 9100
317 # Ethernet8 Ethernet-8 down 100000 9100
318 # Ethernet12 Ethernet-12 down on - 5000
319 # Ethernet16 - down 40000 9100
320 #
321 # show running-configuration interface Ethernet 8
322 # !
323 # interface Ethernet8
324 # mtu 9100
325 # speed 100000
326 # fec AUTO
327 # shutdown
328 #
329 - name: Configure interfaces
330 sonic_interfaces:
331 config:
332 - name: Ethernet8
333 - name: Ethernet12
334 - name: Ethernet16
335 state: deleted
336 #
337 # After state:
338 # -------------
339 #
340 # show interface status | no-more
341 # ------------------------------------------------------------------------------------------
342 # Name Description Admin Oper AutoNeg Speed MTU
343 # ------------------------------------------------------------------------------------------
344 # Ethernet0 - up 100000 9100
345 # Ethernet4 - up 100000 9100
346 # Ethernet8 - up 100000 9100
347 # Ethernet12 - up 100000 9100
348 # Ethernet16 - up 100000 9100
349 #
350 # show running-configuration interface Ethernet 8
351 # !
352 # interface Ethernet8
353 # mtu 9100
354 # speed 100000
355 # shutdown
356 #
357 # Using "deleted" state
358 #
359 # Before state:
360 # -------------
361 #
362 # show interface status | no-more
363 # ------------------------------------------------------------------------------------------
364 # Name Description Admin Oper AutoNeg Speed MTU
365 # ------------------------------------------------------------------------------------------
366 # Ethernet0 - up 100000 9100
367 # Ethernet4 - up 100000 9100
368 # Ethernet8 - down 100000 9100
369 # Ethernet12 - down 1000 9100
370 # Ethernet16 - down 100000 9100
371 #
372 - name: Configure interfaces
373 sonic_interfaces:
374 config:
375
376 state: deleted
377 #
378 # After state:
379 # -------------
380 #
381 # show interface status | no-more
382 # ------------------------------------------------------------------------------------------
383 # Name Description Admin Oper AutoNeg Speed MTU
384 # ------------------------------------------------------------------------------------------
385 # Ethernet0 - up 100000 9100
386 # Ethernet4 - up 100000 9100
387 # Ethernet8 - up 100000 9100
388 # Ethernet12 - up 100000 9100
389 # Ethernet16 - up 100000 9100
390 #
391 #
392 #
393 # Using "merged" state
394 #
395 # Before state:
396 # -------------
397 #
398 # show interface status | no-more
399 # ------------------------------------------------------------------------------------------
400 # Name Description Admin Oper AutoNeg Speed MTU
401 # ------------------------------------------------------------------------------------------
402 # Ethernet0 - up 100000 9100
403 # Ethernet4 - up 100000 9100
404 # Ethernet8 - down 100000 9100
405 # Ethernet12 - down 100000 9100
406 # Ethernet16 - down 100000 9100
407 #
408 # show running-configuration interface Ethernet 8
409 # !
410 # interface Ethernet8
411 # mtu 9100
412 # speed 100000
413 # shutdown
414 #
415 - name: Configure interfaces
416 sonic_interfaces:
417 config:
418 - name: Ethernet8
419 fec: FEC_AUTO
420 - name: Ethernet12
421 description: 'Ethernet Twelve'
422 auto_negotiate: true
423 - name: Ethernet16
424 description: 'Ethernet Sixteen'
425 enabled: true
426 mtu: 3500
427 speed: SPEED_40GB
428 state: merged
429 #
430 # After state:
431 # ------------
432 #
433 # show interface status | no-more
434 # ------------------------------------------------------------------------------------------
435 # Name Description Admin Oper AutoNeg Speed MTU
436 # ------------------------------------------------------------------------------------------
437 # Ethernet0 - up 100000 9100
438 # Ethernet4 - up 100000 9100
439 # Ethernet8 - down 100000 9100
440 # Ethernet12 Ethernet Twelve down on 100000 9100
441 # Ethernet16 Ethernet Sixteen up 40000 3500
442 #
443 # show running-configuration interface Ethernet 8
444 # !
445 # interface Ethernet8
446 # mtu 9100
447 # speed 100000
448 # fec AUTO
449 # shutdown
450 #
451 # Using "overridden" state
452 #
453 # Before state:
454 # -------------
455 #
456 # show interface status | no-more
457 # ------------------------------------------------------------------------------------------
458 # Name Description Admin Oper AutoNeg Speed MTU
459 # ------------------------------------------------------------------------------------------
460 # Ethernet0 E0 up 100000 9100
461 # Ethernet4 E4 up 100000 9100
462 # Ethernet8 E8 down 100000 9100
463 # Ethernet12 - down 1000 9100
464 # Ethernet16 - down 100000 9100
465 #
466 # show running-configuration interface Ethernet 8
467 # !
468 # interface Ethernet8
469 # mtu 9100
470 # speed 100000
471 # shutdown
472 #
473 - name: Configure interfaces
474 sonic_interfaces:
475 config:
476 - name: Ethernet8
477 fec: FEC_AUTO
478 - name: Ethernet12
479 description: 'Ethernet Twelve'
480 mtu: 3500
481 enabled: true
482 auto_negotiate: true
483 - name: Ethernet16
484 description: 'Ethernet Sixteen'
485 mtu: 3000
486 enabled: false
487 speed: SPEED_40GB
488 state: overridden
489 #
490 # After state:
491 # ------------
492 #
493 # show interface status | no-more
494 # ------------------------------------------------------------------------------------------
495 # Name Description Admin Oper AutoNeg Speed MTU
496 # ------------------------------------------------------------------------------------------
497 # Ethernet0 - down 100000 9100
498 # Ethernet4 - down 100000 9100
499 # Ethernet8 - down 100000 9100
500 # Ethernet12 Ethernet Twelve up on 100000 3500
501 # Ethernet16 Ethernet Sixteen down 40000 3000
502 #
503 # show running-configuration interface Ethernet 8
504 # !
505 # interface Ethernet8
506 # mtu 9100
507 # speed 100000
508 # fec AUTO
509 # no shutdown
510 #
511 # Using "replaced" state
512 #
513 # Before state:
514 # -------------
515 #
516 # show interface status | no-more
517 # ------------------------------------------------------------------------------------------
518 # Name Description Admin Oper AutoNeg Speed MTU
519 # ------------------------------------------------------------------------------------------
520 # Ethernet0 - up 100000 9100
521 # Ethernet4 - up 100000 9100
522 # Ethernet8 - down on 100000 9100
523 # Ethernet12 - down 1000 9100
524 # Ethernet16 - down 100000 9100
525 #
526 # show running-configuration interface Ethernet 8
527 # !
528 # interface Ethernet8
529 # mtu 9100
530 # speed auto 40000
531 # shutdown
532 #
533 - name: Configure interfaces
534 sonic_interfaces:
535 config:
536 - name: Ethernet8
537 auto_negotiate: true
538 advertised_speed:
539 - "100000"
540 - name: Ethernet12
541 description: 'Ethernet Twelve'
542 mtu: 3500
543 enabled: true
544 auto_negotiate: true
545 - name: Ethernet16
546 description: 'Ethernet Sixteen'
547 mtu: 3000
548 enabled: false
549 speed: SPEED_40GB
550 state: replaced
551 #
552 # After state:
553 # ------------
554 #
555 # show interface status | no-more
556 # ------------------------------------------------------------------------------------------
557 # Name Description Admin Oper AutoNeg Speed MTU
558 # ------------------------------------------------------------------------------------------
559 # Ethernet0 - up 100000 9100
560 # Ethernet4 - up 100000 9100
561 # Ethernet8 - down on 100000 9100
562 # Ethernet12 Ethernet Twelve up on 100000 3500
563 # Ethernet16 Ethernet Sixteen down 40000 3000
564 #
565 # show running-configuration interface Ethernet 8
566 # !
567 # interface Ethernet8
568 # mtu 9100
569 # speed auto 100000
570 # fec AUTO
571 # shutdown
572 #
573 # Using "deleted" state for MSA/BAM config
574 #
575 # Before state:
576 # -------------
577 # show interface status
578 # --------------------------------------------------------------------------------------------------------------------------------------
579 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
580 # --------------------------------------------------------------------------------------------------------------------------------------
581 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
582 # Ethernet8 Ethernet8 down no-transceiver on - 9100 Eth1/2
583 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
584 #
585 # show running-configuration interface Ethernet 8
586 # !
587 # interface Ethernet8
588 # description Ethernet8
589 # mtu 9100
590 # speed auto MSA
591 # fec RS
592 # unreliable-los auto
593 # no shutdown
594 #
595 - name: Configure interfaces
596 sonic_interfaces:
597 config:
598 - name: Ethernet32
599 autoneg_mode: AUTONEG_MODE_MSA
600 state: deleted
601 #
602 # After State :
603 # -------------
604 # show interface status
605 # --------------------------------------------------------------------------------------------------------------------------------------
606 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
607 # --------------------------------------------------------------------------------------------------------------------------------------
608 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
609 # Ethernet8 Ethernet8 down no-transceiver on - 9100 Eth1/2
610 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
611 #
612 # show running-configuration interface Ethernet 8
613 # !
614 # interface Ethernet8
615 # description Ethernet8
616 # mtu 9100
617 # speed auto
618 # fec RS
619 # unreliable-los auto
620 # no shutdown
621 #
622 # Using "merged" state for MSA/BAM config
623 #
624 # Before state:
625 # -------------
626 # show interface status
627 # --------------------------------------------------------------------------------------------------------------------------------------
628 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
629 # --------------------------------------------------------------------------------------------------------------------------------------
630 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
631 # Ethernet8 Ethernet8 down no-transceiver on - 9100 Eth1/2
632 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
633 #
634 # show running-configuration interface Ethernet 8
635 # !
636 # interface Ethernet8
637 # description Ethernet8
638 # mtu 9100
639 # speed auto
640 # fec RS
641 # unreliable-los auto
642 # no shutdown
643 #
644 - name: Configure interfaces
645 sonic_interfaces:
646 config:
647 - name: Ethernet32
648 autoneg_mode: AUTONEG_MODE_MSA
649 state: merged
650 #
651 # After state:
652 # -------------
653 #
654 # show interface status
655 # --------------------------------------------------------------------------------------------------------------------------------------
656 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
657 # --------------------------------------------------------------------------------------------------------------------------------------
658 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
659 # Ethernet8 Ethernet8 down no-transceiver on - 9100 Eth1/2
660 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
661 #
662 # show running-configuration interface Ethernet 8
663 # !
664 # interface Ethernet8
665 # description Ethernet8
666 # mtu 9100
667 # speed auto MSA
668 # fec RS
669 # unreliable-los auto
670 # no shutdown
671 #
672 # Using "replaced" state for MSA/BAM config
673 #
674 # Before state:
675 # -------------
676 #
677 # show interface status
678 # --------------------------------------------------------------------------------------------------------------------------------------
679 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
680 # --------------------------------------------------------------------------------------------------------------------------------------
681 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
682 # Ethernet8 Ethernet8 down admin-down on - 9100 Eth1/2
683 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
684 #
685 # show running-configuration interface Ethernet 8
686 # !
687 # interface Ethernet8
688 # description Ethernet8
689 # mtu 9100
690 # speed auto MSA
691 # fec RS
692 # unreliable-los auto
693 # shutdown
694 #
695 - name: configure interface
696 sonic_interfaces:
697 config:
698 - name: Ethernet8
699 description: 'Ethernet eight'
700 state: replaced
701 #
702 # After state:
703 # -------------
704 #
705 # show interface status
706 # --------------------------------------------------------------------------------------------------------------------------------------
707 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
708 # --------------------------------------------------------------------------------------------------------------------------------------
709 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
710 # Ethernet8 Ethernet eight down admin-down off 800000 9100 Eth1/2
711 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
712 #
713 # show running-configuration interface Ethernet 8
714 # !
715 # interface Ethernet8
716 # description "Ethernet eight"
717 # mtu 9100
718 # speed 800000
719 # fec RS
720 # unreliable-los auto
721 # shutdown
722 #
723 # Using "replaced" state for MSA/BAM config
724 #
725 # Before state:
726 # -------------
727 #
728 # show interface status
729 # --------------------------------------------------------------------------------------------------------------------------------------
730 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
731 # --------------------------------------------------------------------------------------------------------------------------------------
732 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
733 # Ethernet8 Ethernet8 down admin-down off 800000 9100 Eth1/2
734 #
735 # show running-configuration interface Ethernet 8
736 # !
737 # interface Ethernet8
738 # description Ethernet8
739 # mtu 9100
740 # speed 800000
741 # fec AUTO
742 # unreliable-los auto
743 # shutdown
744 #
745 - name: configure interface
746 sonic_interfaces:
747 config:
748 - name: Ethernet8
749 auto_negotiate: true
750 autoneg_mode: AUTONEG_MODE_MSA
751 state: replaced
752 #
753 # After state:
754 # -------------
755 # show interface status
756 # --------------------------------------------------------------------------------------------------------------------------------------
757 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
758 # --------------------------------------------------------------------------------------------------------------------------------------
759 # Ethernet0 Ethernet0 down no-transceiver off 800000 9100 Eth1/1
760 # Ethernet8 - down admin-down on - 9100 Eth1/2
761 # Ethernet16 - down no-transceiver off 800000 9100 Eth1/3
762 #
763 # show running-configuration interface Ethernet 8
764 # !
765 # interface Ethernet8
766 # mtu 9100
767 # speed auto MSA
768 # fec RS
769 # unreliable-los auto
770 # shutdown
771 #
772 # Using "overridden" state for MSA/BAM config
773 #
774 # Before state:
775 # -------------
776 # show interface status
777 # --------------------------------------------------------------------------------------------------------------------------------------
778 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
779 # --------------------------------------------------------------------------------------------------------------------------------------
780 # Ethernet0 Ethernet0 down admin-down on - 5432 Eth1/1
781 # Ethernet8 Ethernet8 down no-transceiver on - 4532 Eth1/2
782 # Ethernet16 - down admin-down off 800000 9100 Eth1/3
783 #
784 # show running-configuration interface Ethernet 0
785 # !
786 # interface Ethernet0
787 # description Ethernet0
788 # mtu 5432
789 # speed auto MSA
790 # fec RS
791 # unreliable-los auto
792 # shutdown
793 #
794 # show running-configuration interface Ethernet 8
795 # !
796 # interface Ethernet8
797 # description Ethernet8
798 # mtu 4532
799 # speed auto MSA
800 # fec RS
801 # unreliable-los auto
802 # no shutdown
803 #
804 - name: configure interface
805 dellemc.enterprise_sonic.sonic_interfaces:
806 config:
807 - name: Ethernet8
808 description: 'Ethernet eight'
809 state: overridden
810 #
811 # After state:
812 # -------------
813 # show interface status
814 # --------------------------------------------------------------------------------------------------------------------------------------
815 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
816 # --------------------------------------------------------------------------------------------------------------------------------------
817 # Ethernet0 - down admin-down off 800000 9100 Eth1/1
818 # Ethernet8 Ethernet eight down admin-down off 800000 9100 Eth1/2
819 # Ethernet16 - down admin-down off 800000 9100 Eth1/3
820 #
821 # show running-configuration interface Ethernet 0
822 # !
823 # interface Ethernet0
824 # mtu 9100
825 # speed 800000
826 # fec RS
827 # unreliable-los auto
828 # shutdown
829 # show running-configuration interface Ethernet 8
830 # !
831 # interface Ethernet8
832 # description "Ethernet eight"
833 # mtu 9100
834 # speed 800000
835 # fec RS
836 # unreliable-los auto
837 # shutdown
838 # sonic#
839 #
840 # Using "overridden" state for MSA/BAM config
841 #
842 # Before state:
843 # -------------
844 # show interface status
845 # --------------------------------------------------------------------------------------------------------------------------------------
846 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
847 # --------------------------------------------------------------------------------------------------------------------------------------
848 # Ethernet0 Ethernet0 down admin-down off 400000 5432 Eth1/1
849 # Ethernet8 Ethernet eight down no-transceiver off 800000 4352 Eth1/2
850 # Ethernet16 - down admin-down off 800000 9100 Eth1/3
851 #
852 # show running-configuration interface Ethernet 0
853 # !
854 # interface Ethernet0
855 # description Ethernet0
856 # mtu 5432
857 # speed 400000
858 # fec RS
859 # unreliable-los auto
860 # shutdown
861 #
862 # show running-configuration interface Ethernet 8
863 # !
864 # interface Ethernet8
865 # description "Ethernet eight"
866 # mtu 4352
867 # speed 800000
868 # fec RS
869 # unreliable-los auto
870 # no shutdown
871 - name: configure interface
872 sonic_interfaces:
873 config:
874 - name: Ethernet8
875 auto_negotiate: true
876 autoneg_mode: AUTONEG_MODE_MSA
877 state: overridden
878 #
879 # After state:
880 # -------------
881 # show interface status
882 # --------------------------------------------------------------------------------------------------------------------------------------
883 # Name Description Oper Reason AutoNeg Speed MTU Alternate Name
884 # --------------------------------------------------------------------------------------------------------------------------------------
885 # Ethernet0 - down admin-down off 800000 9100 Eth1/1
886 # Ethernet8 - down admin-down on - 9100 Eth1/2
887 # Ethernet16 - down admin-down off 800000 9100 Eth1/3
888 #
889 # show running-configuration interface Ethernet 0
890 # !
891 # interface Ethernet0
892 # mtu 9100
893 # speed 800000
894 # fec RS
895 # unreliable-los auto
896 # shutdown
897 #
898 # show running-configuration interface Ethernet 8
899 # !
900 # interface Ethernet8
901 # mtu 9100
902 # speed auto MSA
903 # fec RS
904 # unreliable-los auto
905 # shutdown
906
907
908
909 Return Values
910 -------------
911 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:
912
913 .. raw:: html
914
915 <table border=0 cellpadding=0 class="documentation-table">
916 <tr>
917 <th colspan="1">Key</th>
918 <th>Returned</th>
919 <th width="100%">Description</th>
920 </tr>
921 <tr>
922 <td colspan="1">
923 <div class="ansibleOptionAnchor" id="return-"></div>
924 <b>after</b>
925 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
926 <div style="font-size: small">
927 <span style="color: purple">list</span>
928 </div>
929 </td>
930 <td>when changed</td>
931 <td>
932 <div>The resulting configuration module invocation.</div>
933 <br/>
934 <div style="font-size: smaller"><b>Sample:</b></div>
935 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">The configuration returned is always in the same format as the parameters above.</div>
936 </td>
937 </tr>
938 <tr>
939 <td colspan="1">
940 <div class="ansibleOptionAnchor" id="return-"></div>
941 <b>before</b>
942 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
943 <div style="font-size: small">
944 <span style="color: purple">list</span>
945 </div>
946 </td>
947 <td>always</td>
948 <td>
949 <div>The configuration prior to the module invocation.</div>
950 <br/>
951 <div style="font-size: smaller"><b>Sample:</b></div>
952 <div style="font-size: smaller; color: blue; word-wrap: break-word; word-break: break-all;">The configuration returned is always in the same format as the parameters above.</div>
953 </td>
954 </tr>
955 <tr>
956 <td colspan="1">
957 <div class="ansibleOptionAnchor" id="return-"></div>
958 <b>commands</b>
959 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
960 <div style="font-size: small">
961 <span style="color: purple">list</span>
962 </div>
963 </td>
964 <td>always</td>
965 <td>
966 <div>The set of commands pushed to the remote device.</div>
967 <br/>
968 <div style="font-size: smaller"><b>Sample:</b></div>
969 <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>
970 </td>
971 </tr>
972 </table>
973 <br/><br/>
974
975
976 Status
977 ------
978
979
980 Authors
981 ~~~~~~~
982
983 - Niraimadaiselvam M(@niraimadaiselvamm)