Skip to content
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

[202205] Backport: Rename the platform_reboot to the pre_reboot_hook, remove the sysfs power cycle #21686

Closed
wants to merge 1 commit into from

Conversation

jianyuewu
Copy link

@jianyuewu jianyuewu commented Feb 10, 2025

Backport commit #18324.

Why I did it

Back port graceful reboot instead of the sysfs power cycle to avoid filesystem corruption.

How I did it

Rename the platform_reboot script to the pre_reboot_hook. Remove the sysfs power cycle function, from now on the Debian reboot (/sbin/reboot) will be executed instead of the sysfs power cycle.

How to verify it

Start watching logs by using show log -f and journalctl -p debug -f.
Execute the reboot command from the switch CLI.
Check in logs that all systemd services terminated.

Which release branch to backport (provide reason below if selected)

  • 202205

Because 202205 branch is missing this change.

Tested branch (Please provide the tested image version)

SONiC.202205_5_rc.7-3349088e1

@mssonicbld
Copy link
Collaborator

/azp run Azure.sonic-buildimage

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

/azpw

@jianyuewu jianyuewu force-pushed the 202205_reboot_precheck branch from b11f1ef to 79b84b1 Compare February 13, 2025 12:42
@mssonicbld
Copy link
Collaborator

/azp run Azure.sonic-buildimage

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link
Collaborator

/azp run Azure.sonic-buildimage

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Back port from master branch.

Why I did it
Back port graceful reboot instead of the sysfs power cycle to avoid
filesystem corruption.

How I did it
Rename the platform_reboot script to the pre_reboot_hook. Remove the
sysfs power cycle function, from now on the Debian reboot (/sbin/reboot)
will be executed instead of the sysfs power cycle.

How to verify it
Start watching logs by using show log -f and journalctl -p debug -f.
Execute the reboot command from the switch CLI.
Check in logs that all systemd services terminated.

Signed-off-by: Jianyue Wu <jianyuew@nvidia.com>
@jianyuewu jianyuewu force-pushed the 202205_reboot_precheck branch from 389bc0f to d5c93e4 Compare February 14, 2025 00:48
@mssonicbld
Copy link
Collaborator

/azp run Azure.sonic-buildimage

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

Seems failure caused by "ImportError: /usr/lib/arm-linux-gnueabihf/libstdc++.so.6: version `GLIBCXX_3.4.29' not found"

@jianyuewu
Copy link
Author

/azp run Azure.sonic-buildimage

Copy link

Commenter does not have sufficient privileges for PR 21686 in repo sonic-net/sonic-buildimage

@jianyuewu
Copy link
Author

/azpw run

@mssonicbld
Copy link
Collaborator

/AzurePipelines run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

Pending on build fix PR merge: sonic-net/sonic-swss-common#977

@jianyuewu
Copy link
Author

/azpw run

@mssonicbld
Copy link
Collaborator

/AzurePipelines run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

/azpw run

@mssonicbld
Copy link
Collaborator

/AzurePipelines run

@jianyuewu
Copy link
Author

/azpw run

@mssonicbld
Copy link
Collaborator

/AzurePipelines run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

/azpw run

@mssonicbld
Copy link
Collaborator

/AzurePipelines run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jianyuewu
Copy link
Author

Now error is:
Cloning into 'flashrom-0.9.7'...
/sonic/src/flashrom/flashrom-0.9.7 /sonic/src/flashrom
fatal: 'tags/0.9.7' is not a commit and a branch 'flashrom-src' cannot be created from it
Need this PR merge: #21535

@jianyuewu jianyuewu closed this Feb 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants