Debian Codegraph @

ansible_collections/dellemc/enterprise_sonic/docs/dellemc.enterprise_sonic.sonic_ip_neighbor_module.rst

raw
1 .. _dellemc.enterprise_sonic.sonic_ip_neighbor_module:
2
3
4 ******************************************
5 dellemc.enterprise_sonic.sonic_ip_neighbor
6 ******************************************
7
8 **Manage IP neighbor global configuration on SONiC.**
9
10
11 Version added: 2.1.0
12
13 .. contents::
14 :local:
15 :depth: 1
16
17
18 Synopsis
19 --------
20 - This module provides configuration management of IP neighbor global 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="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">dictionary</span>
43 </div>
44 </td>
45 <td>
46 </td>
47 <td>
48 <div>Specifies IP neighbor global configurations.</div>
49 </td>
50 </tr>
51 <tr>
52 <td class="elbow-placeholder"></td>
53 <td colspan="1">
54 <div class="ansibleOptionAnchor" id="parameter-"></div>
55 <b>ipv4_arp_timeout</b>
56 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
57 <div style="font-size: small">
58 <span style="color: purple">integer</span>
59 </div>
60 </td>
61 <td>
62 </td>
63 <td>
64 <div>IPv4 ARP timeout.</div>
65 <div>The range is from 60 to 14400.</div>
66 </td>
67 </tr>
68 <tr>
69 <td class="elbow-placeholder"></td>
70 <td colspan="1">
71 <div class="ansibleOptionAnchor" id="parameter-"></div>
72 <b>ipv4_drop_neighbor_aging_time</b>
73 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
74 <div style="font-size: small">
75 <span style="color: purple">integer</span>
76 </div>
77 </td>
78 <td>
79 </td>
80 <td>
81 <div>IPv4 drop neighbor aging time.</div>
82 <div>The range is from 60 to 14400.</div>
83 </td>
84 </tr>
85 <tr>
86 <td class="elbow-placeholder"></td>
87 <td colspan="1">
88 <div class="ansibleOptionAnchor" id="parameter-"></div>
89 <b>ipv6_drop_neighbor_aging_time</b>
90 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
91 <div style="font-size: small">
92 <span style="color: purple">integer</span>
93 </div>
94 </td>
95 <td>
96 </td>
97 <td>
98 <div>IPv6 drop neighbor aging time.</div>
99 <div>The range is from 60 to 14400.</div>
100 </td>
101 </tr>
102 <tr>
103 <td class="elbow-placeholder"></td>
104 <td colspan="1">
105 <div class="ansibleOptionAnchor" id="parameter-"></div>
106 <b>ipv6_nd_cache_expiry</b>
107 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
108 <div style="font-size: small">
109 <span style="color: purple">integer</span>
110 </div>
111 </td>
112 <td>
113 </td>
114 <td>
115 <div>IPv6 ND cache expiry.</div>
116 <div>The range is from 60 to 14400.</div>
117 </td>
118 </tr>
119 <tr>
120 <td class="elbow-placeholder"></td>
121 <td colspan="1">
122 <div class="ansibleOptionAnchor" id="parameter-"></div>
123 <b>num_local_neigh</b>
124 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
125 <div style="font-size: small">
126 <span style="color: purple">integer</span>
127 </div>
128 </td>
129 <td>
130 </td>
131 <td>
132 <div>The number of reserved local neighbors.</div>
133 <div>The range is from 0 to 32000.</div>
134 </td>
135 </tr>
136
137 <tr>
138 <td colspan="2">
139 <div class="ansibleOptionAnchor" id="parameter-"></div>
140 <b>state</b>
141 <a class="ansibleOptionLink" href="#parameter-" title="Permalink to this option"></a>
142 <div style="font-size: small">
143 <span style="color: purple">string</span>
144 </div>
145 </td>
146 <td>
147 <ul style="margin: 0; padding: 0"><b>Choices:</b>
148 <li><div style="color: blue"><b>merged</b>&nbsp;&larr;</div></li>
149 <li>replaced</li>
150 <li>overridden</li>
151 <li>deleted</li>
152 </ul>
153 </td>
154 <td>
155 <div>The state of the configuration after module completion.</div>
156 </td>
157 </tr>
158 </table>
159 <br/>
160
161
162 Notes
163 -----
164
165 .. note::
166 - Supports ``check_mode``.
167
168
169
170 Examples
171 --------
172
173 .. code-block:: yaml
174
175 #
176 # Using "merged" state
177 #
178 # Before state:
179 # -------------
180 #
181 # sonic# show running-configuration
182 # !
183 # ip arp timeout 180
184 # ip drop-neighbor aging-time 300
185 # ipv6 drop-neighbor aging-time 300
186 # ip reserve local-neigh 0
187 # ipv6 nd cache expire 180
188 # !
189 - name: Configure IP neighbor global
190 sonic_ip_neighbor:
191 config:
192 ipv4_arp_timeout: 1200
193 ipv4_drop_neighbor_aging_time: 600
194 ipv6_drop_neighbor_aging_time: 600
195 ipv6_nd_cache_expiry: 1200
196 num_local_neigh: 1000
197 state: merged
198
199 # After state:
200 # ------------
201 #
202 # sonic# show running-configuration
203 # !
204 # ip arp timeout 1200
205 # ip drop-neighbor aging-time 600
206 # ipv6 drop-neighbor aging-time 600
207 # ip reserve local-neigh 1000
208 # ipv6 nd cache expire 1200
209 # !
210 #
211 # Using "deleted" state
212 #
213 # Before state:
214 # -------------
215 #
216 # sonic# show running-configuration
217 # !
218 # ip arp timeout 1200
219 # ip drop-neighbor aging-time 600
220 # ipv6 drop-neighbor aging-time 600
221 # ip reserve local-neigh 1000
222 # ipv6 nd cache expire 1200
223 # !
224 - name: Delete some IP neighbor configuration
225 sonic_ip_neighbor:
226 config:
227 ipv4_arp_timeout: 0
228 ipv4_drop_neighbor_aging_time: 0
229 state: deleted
230
231 # After state:
232 # ------------
233 #
234 # sonic# show running-configuration
235 # !
236 # ip arp timeout 180
237 # ip drop-neighbor aging-time 300
238 # ipv6 drop-neighbor aging-time 600
239 # ip reserve local-neigh 1000
240 # ipv6 nd cache expire 1200
241 # !
242 #
243 # Using "deleted" state
244 #
245 # Before state:
246 # -------------
247 #
248 # sonic# show running-configuration
249 # !
250 # ip arp timeout 1200
251 # ip drop-neighbor aging-time 600
252 # ipv6 drop-neighbor aging-time 600
253 # ip reserve local-neigh 1000
254 # ipv6 nd cache expire 1200
255 # !
256 - name: Delete all IP neighbor configuration
257 sonic_ip_neighbor:
258 config: {}
259 state: deleted
260
261 # After state:
262 # ------------
263 #
264 # sonic# show running-configuration
265 # !
266 # ip arp timeout 180
267 # ip drop-neighbor aging-time 300
268 # ipv6 drop-neighbor aging-time 300
269 # ip reserve local-neigh 0
270 # ipv6 nd cache expire 180
271 # !
272 #
273 # Using "replaced" state
274 #
275 # Before state:
276 # -------------
277 #
278 # sonic# show running-configuration
279 # !
280 # ip arp timeout 1200
281 # ip drop-neighbor aging-time 600
282 # ipv6 drop-neighbor aging-time 300
283 # ip reserve local-neigh 0
284 # ipv6 nd cache expire 180
285 # !
286 - name: Change some IP neighbor configuration
287 sonic_ip_neighbor:
288 config:
289 ipv6_drop_neighbor_aging_time: 600
290 ipv6_nd_cache_expiry: 1200
291 num_local_neigh: 1000
292 state: replaced
293
294 # After state:
295 # ------------
296 #
297 # sonic# show running-configuration
298 # !
299 # ip arp timeout 1200
300 # ip drop-neighbor aging-time 600
301 # ipv6 drop-neighbor aging-time 600
302 # ip reserve local-neigh 1000
303 # ipv6 nd cache expire 1200
304 # !
305 #
306 # Using "overridden" state
307 #
308 # Before state:
309 # -------------
310 #
311 # sonic# show running-configuration
312 # !
313 # ip arp timeout 1200
314 # ip drop-neighbor aging-time 600
315 # ipv6 drop-neighbor aging-time 300
316 # ip reserve local-neigh 0
317 # ipv6 nd cache expire 180
318 # !
319 - name: Reset IP neighbor configuration, then configure some
320 sonic_ip_neighbor:
321 config:
322 ipv6_drop_neighbor_aging_time: 600
323 ipv6_nd_cache_expiry: 1200
324 num_local_neigh: 1000
325 state: overridden
326
327 # After state:
328 # ------------
329 #
330 # sonic# show running-configuration
331 # !
332 # ip arp timeout 180
333 # ip drop-neighbor aging-time 300
334 # ipv6 drop-neighbor aging-time 600
335 # ip reserve local-neigh 1000
336 # ipv6 nd cache expire 1200
337 # !
338 #
339
340
341
342 Return Values
343 -------------
344 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:
345
346 .. raw:: html
347
348 <table border=0 cellpadding=0 class="documentation-table">
349 <tr>
350 <th colspan="1">Key</th>
351 <th>Returned</th>
352 <th width="100%">Description</th>
353 </tr>
354 <tr>
355 <td colspan="1">
356 <div class="ansibleOptionAnchor" id="return-"></div>
357 <b>after</b>
358 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
359 <div style="font-size: small">
360 <span style="color: purple">list</span>
361 </div>
362 </td>
363 <td>when changed</td>
364 <td>
365 <div>The resulting configuration module invocation.</div>
366 <br/>
367 <div style="font-size: smaller"><b>Sample:</b></div>
368 <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 as the parameters above.</div>
369 </td>
370 </tr>
371 <tr>
372 <td colspan="1">
373 <div class="ansibleOptionAnchor" id="return-"></div>
374 <b>after_generated</b>
375 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
376 <div style="font-size: small">
377 <span style="color: purple">list</span>
378 </div>
379 </td>
380 <td>when <code>check_mode</code></td>
381 <td>
382 <div>The generated configuration module invocation.</div>
383 <br/>
384 <div style="font-size: smaller"><b>Sample:</b></div>
385 <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 as the parameters above.</div>
386 </td>
387 </tr>
388 <tr>
389 <td colspan="1">
390 <div class="ansibleOptionAnchor" id="return-"></div>
391 <b>before</b>
392 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
393 <div style="font-size: small">
394 <span style="color: purple">list</span>
395 </div>
396 </td>
397 <td>always</td>
398 <td>
399 <div>The configuration prior to the module invocation.</div>
400 <br/>
401 <div style="font-size: smaller"><b>Sample:</b></div>
402 <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 as the parameters above.</div>
403 </td>
404 </tr>
405 <tr>
406 <td colspan="1">
407 <div class="ansibleOptionAnchor" id="return-"></div>
408 <b>commands</b>
409 <a class="ansibleOptionLink" href="#return-" title="Permalink to this return value"></a>
410 <div style="font-size: small">
411 <span style="color: purple">list</span>
412 </div>
413 </td>
414 <td>always</td>
415 <td>
416 <div>The set of commands pushed to the remote device.</div>
417 <br/>
418 <div style="font-size: smaller"><b>Sample:</b></div>
419 <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>
420 </td>
421 </tr>
422 </table>
423 <br/><br/>
424
425
426 Status
427 ------
428
429
430 Authors
431 ~~~~~~~
432
433 - M\. Zhang (@mingjunzhang2019)