[reboot-cause] Fixed determine-reboot-cause.service failure. (#8210)
Signed-off-by: Rajkumar Pennadam Ramamoorthy rpennadamram@marvell.com Why I did it Install sonic image from ONIE. Once system is up, execute "config reload" command. Root cause is that "determine-reboot-cause.service" was in failed state. root@sonic:/host/reboot-cause# systemctl list-units --failed UNIT LOAD ACTIVE SUB DESCRIPTION ● determine-reboot-cause.service loaded failed failed Reboot cause determination service How I did it Fixed the issue by setting default reason to "REBOOT_CAUSE_UNKNOWN" instead of "None". How to verify it Check " determine-reboot-cause.service' loaded successfully post image installation from ONIE. Verify "reboot-cause.txt" file is created and config reload succeeds.
This commit is contained in:
parent
14da7a1663
commit
d6433d1adc
@ -62,7 +62,7 @@ def parse_warmfast_reboot_from_proc_cmdline():
|
||||
|
||||
|
||||
def find_software_reboot_cause_from_reboot_cause_file():
|
||||
software_reboot_cause = None
|
||||
software_reboot_cause = REBOOT_CAUSE_UNKNOWN
|
||||
if os.path.isfile(REBOOT_CAUSE_FILE):
|
||||
with open(REBOOT_CAUSE_FILE) as cause_file:
|
||||
software_reboot_cause = cause_file.readline().rstrip('\n')
|
||||
|
Loading…
Reference in New Issue
Block a user