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

[PMON] Extend pmon daemon start control to lm-sensors and fancontrol for 201911 #4487

Merged
merged 2 commits into from
Apr 29, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"skip_ledd": true
"skip_ledd": true,
"skip_fancontrol": true
}

Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ autorestart=false
stdout_logfile=syslog
stderr_logfile=syslog

{% if not skip_sensors %}
[program:lm-sensors]
command=/usr/bin/lm-sensors.sh
priority=3
Expand All @@ -34,7 +35,9 @@ autorestart=false
stdout_logfile=syslog
stderr_logfile=syslog
startsecs=0
{% endif %}

{% if not skip_fancontrol %}
[program:fancontrol]
command=/usr/sbin/fancontrol
priority=4
Expand All @@ -43,6 +46,7 @@ autorestart=unexpected
stdout_logfile=syslog
stderr_logfile=syslog
startsecs=10
{% endif %}

{% if not skip_ledd %}
[program:ledd]
Expand Down
4 changes: 4 additions & 0 deletions dockers/docker-platform-monitor/start.sh.j2
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,17 @@ if [ -e /usr/share/sonic/platform/platform_wait ]; then
fi
fi

{% if not skip_sensors %}
# If this platform has an lm-sensors config file, copy it to it's proper place
# and start lm-sensors
if [ -e /usr/share/sonic/platform/sensors.conf ]; then
mkdir -p /etc/sensors.d
/bin/cp -f /usr/share/sonic/platform/sensors.conf /etc/sensors.d/
supervisorctl start lm-sensors
fi
{% endif %}

{% if not skip_fancontrol %}
# If this platform has a fancontrol config file, copy it to it's proper place
# and start fancontrol
if [ -e /usr/share/sonic/platform/fancontrol ]; then
Expand All @@ -36,6 +39,7 @@ if [ -e /usr/share/sonic/platform/fancontrol ]; then
/bin/cp -f /usr/share/sonic/platform/fancontrol /etc/
supervisorctl start fancontrol
fi
{% endif %}


# If the sonic-platform package is not installed, try to install it
Expand Down