sonic-buildimage/device/nokia/x86_64-nokia_ixr7250e_sup-r0/platform_reboot

17 lines
555 B
Plaintext
Raw Normal View History

#!/bin/bash
echo "Rebooting all Linecards"
python3 -c 'import sonic_platform.platform; platform_chassis = sonic_platform.platform.Platform().get_chassis(); platform_chassis.reboot_imms()'
sleep 3
systemctl stop nokia-watchdog.service
sleep 2
echo "w" > /dev/watchdog
kick_date=`date -u`
echo "last watchdog kick $kick_date" > /var/log/nokia-watchdog-last.log
rm -f /sys/firmware/efi/efivars/dump-*
touch /etc/opt/srlinux/devmgr_reboot_cause.done
rm -f /etc/opt/srlinux/reboot-cause.txt
echo "Shutdown midplane"
ifconfig xe0 down
sync
exec /sbin/reboot $@