-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove PMON and XCVRD delay on system boot for modules controlled by SW #18295
Remove PMON and XCVRD delay on system boot for modules controlled by SW #18295
Conversation
@vadymhlushko-mlnx is this cleanly cherry picked to 202311 or we need a dedicate PR? if such is required we should have the label set properly and relate to the new PR against 202311. |
I've already created a separate PR for 202311 - [202311][IM] Remove the PMON and XCVRD delay on system boot #18296 |
088b785
to
dd7317c
Compare
@prgeor could you please help to merge |
files/scripts/syncd.sh
Outdated
/bin/systemctl start pmon | ||
debug "Started pmon service" | ||
fi | ||
debug "Starting pmon service..." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx Why will Systemd not start the PMON early? Why not remove "After=Syncd" for your platform?
After=syncd.service |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx would you please check the comments?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@prgeor XCVRD
should be started after we create_switch
and initialize all the ports, that is why we have a dependency for the syncd
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx There is already a dependency between Xcvrd and Swss. Xcvrd waits for PortInitDone and untill portsyncd sets its after all host interfaces are created: https://github.com/sonic-net/sonic-swss/blob/19410232523283d99eaa211979cc1e58b6cb262f/portsyncd/portsyncd.cpp#L134
We are holding complete PMON init just for Xcvrd which doesn't seems right. Can we use PortInitDone as a synchronization?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@prgeor
This PR goal is to start the XCVRD CMIS manager task as soon as possible to link UP the SW-controlled ports as quickly as possible during the fastboot.
The XCVRD CMISMangerTaks already using the PortInitDone sync mechanism.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx synchronization via systemd service file is fine. Why do we need to start pmon from synch.sh?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx let systemd do the synchronization between syncd and pmon service
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@prgeor Some services are started by shell scripts, some via systemd. Both approaches work in SONiC. Starting from shell script gives more flexibility
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@prgeor I've removed unused code from the syncd.sh
as you requested
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx OK. is the PR still in draft or ready for review?
dd7317c
to
0cd7f5f
Compare
0cd7f5f
to
cf77741
Compare
cf77741
to
b33ccc8
Compare
b33ccc8
to
51b745e
Compare
202311 branch cherry-pick |
665dd46
to
eed6e6c
Compare
@prgeor , Can you please review as your comment was addressed ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vadymhlushko-mlnx please use systemd for synchronization between PMON and syncd
Signed-off-by: vadymhlushko-mlnx <[email protected]>
Signed-off-by: vadymhlushko-mlnx <[email protected]>
aab3be6
to
c400723
Compare
New PR will be opened by @stepanblyschak |
Why I did it
To support the
fastboot
feature alongsidemodule controlled by sw
feature.Because if the feature is enabled we need the
XCVRD
to start as soon as possible to identify if the port isSW
orFW
controlled and bring the port to the UP state.Work item tracking
How I did it
Remove the delays for the
PMON
docker andXCVRD
daemon on the SONiC image start.How to verify it
Run the sonic-mgmt/tests/platform_tests/test_advanced_reboot.py - test_fast_reboot
Which release branch to backport (provide reason below if selected)
Tested branch (Please provide the tested image version)
Description for the changelog
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)