sonic-buildimage/platform
Sasha 26bc08850b
Check if PSU files exists when getting psu_voltage properties (#17042)
- Why I did it
Error messages occured when trying to read PSU files on init:
ERR pmon#psud: Failed to read from file /var/run/hw-management/power/psu1_volt_out2_capability - FileNotFoundError(2, 'No such file or directory')

This can happen when the power cord is disconnected from the PSU, so some PSU files may be absent, e.g.:
/var/run/hw-management/power/psu2_volt_out2
/var/run/hw-management/power/psu2_volt_out2_capability

- How I did it
Check if a file exists for a specific PSU parameter If not, return None so we can't read the PSU file any further

- How to verify it
Disconnect power cord from PSU and power supply from system
Wait few minutes and then connect power supply to system without power cord
Check logs for errors

Signed-off-by: Oleksandra Bella <oleksandrab@nvidia.com>
2024-03-04 19:35:06 +02:00
..
barefoot Update sonic-linux-kernel to use 6.1.38 2023-11-21 18:53:15 -08:00
broadcom [build] Use public storage for public resources. (#18038) 2024-02-27 17:45:49 -08:00
cavium [infra] Support syslog rate limit configuration (#12490) 2022-12-20 10:53:58 +02:00
centec [Bookworm] Upgrade centec platforms to Bookworm (#17364) 2023-12-01 16:07:52 -08:00
centec-arm64 [Bookworm] Upgrade centec-arm64 platform to Bookworm. (#17411) 2023-12-07 08:42:13 -08:00
checkout Update cisco-8000.ini (#17428) 2023-12-07 17:05:05 -08:00
components [build] Use public storage for public resources. (#18038) 2024-02-27 17:45:49 -08:00
generic [dockers] Rename 'docker-snmp-sv2' to 'docker-snmp' (#4699) 2020-06-11 16:04:23 -07:00
innovium Why I did it (#14826) 2023-07-30 09:48:36 -07:00
marvell [Marvell] Updated SAI 1.13.0 amd64 debian (#16811) 2023-10-18 16:47:53 +08:00
marvell-arm64 [Marvell-arm64] Update sonic-platform submodule (#17717) 2024-02-28 11:43:48 -08:00
marvell-armhf [Nokia-7215-T1] Disable sysrq-trigger from platform init (#18161) 2024-02-28 08:24:01 -08:00
mellanox Check if PSU files exists when getting psu_voltage properties (#17042) 2024-03-04 19:35:06 +02:00
nephos [build] Use public storage for public resources. (#18038) 2024-02-27 17:45:49 -08:00
p4 docker prefer COPY to ADD in dockerfile (#15394) 2023-06-22 13:16:56 -07:00
pddf [Edgecore][sonic-platform-modules-accton]Support kernel 6.1 and bookworm (#16982) 2023-11-21 18:53:15 -08:00
pensando Add pensando platform (#15978) 2023-12-04 14:41:52 -08:00
s3ip-sysfs The CPLD and FPGA driver framework module complies with s3ip sysfs specification (#12891) 2022-12-16 22:05:53 +08:00
template Mount directory warmboot in docker gbsyncd (#11852) 2022-08-26 22:00:45 +08:00
vs [build] Use public storage for public resources. (#18038) 2024-02-27 17:45:49 -08:00