sonic-utilities icon indicating copy to clipboard operation
sonic-utilities copied to clipboard

Optimize lag_keepalive by crafting the LACPDU packet ourselves

Open saiarcot895 opened this issue 1 year ago • 4 comments

What I did

Instead of waiting for a LACPDU packet to be sent and capturing that (which involves waiting roughly 30 seconds), get the necessary information from teamd and craft it ourselves. This means that the 60-second wait in making sure that a LACPDU packet is captured and the keepalive script is ready can be largely eliminated (this has been reduced to 10 seconds to make sure the script has a chance to craft the packets and send some LACPDUs).

Fixes sonic-net/sonic-buildimage#17416.

How I did it

How to verify it

Verified on KVM that the lag_keepalive script started correctly. Also verified that during a warm-reboot, the script correctly starts and send LACPDU packets every second (the delay between starting the script and the message where it said it is ready was 2 seconds).

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

saiarcot895 avatar Feb 19 '24 19:02 saiarcot895

/azp run Azure.sonic-utilities

xumia avatar Feb 22 '24 04:02 xumia

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Feb 22 '24 04:02 azure-pipelines[bot]