-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Install Superlance plugins to monitor and control process that run un… #19097
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
base: master
Are you sure you want to change the base?
Conversation
dockers/docker-base/Dockerfile.j2
Outdated
@@ -64,6 +64,7 @@ RUN pip install wheel | |||
|
|||
# Install supervisor | |||
RUN pip install supervisor>=3.4.0 | |||
RUN pip install superlance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use docker-base-bullseye and docker-base-bookworm. docker-base isn't used anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@saiarcot895 thanks .removed
The PR description says 100KB is the limit, but the actual change sets it to 100MB. Can you update the PR description? |
Has the restart logic been tested? |
manually installed the superlance package inside PMON and then it was tested. I am awaiting the build to be generated to test with latest image |
/azp run Azure.sonic-buildimage |
Azure Pipelines successfully started running 1 pipeline(s). |
need more thorough testing. like, what is rsyslogd consistent reaching the 100MB, is there any restart limit? what is the syslog messages, if there many rsyslogd restart due to this, do we have alert? does this impact boot time, if yes, how many? there are many other dockers having rsyslogd, why only these dockers? |
@lguohan
@lguohan Typical memory usage of rsylogd is few MBs and I selected 100M which is not too small (in which case on a chatty device there will be frequent rsyslogd restarts in short period of time) and not too large threshold (in which case monit may complain high memory usage on platforms having less RAM memory.) We will see rsyslogd daemon restart message in supervisord log message similar to any docker container process restart by supervisord. We can have alerting to alert on these message signatures. |
@prgeor as I see it, 100MB is too much, this represent of about 2000% memory usage of normal rsyslog consumption. If we only look on one docker, then 100MB might not seem much, but looking on the total amount of used memory in the switch, if it has gotten close to this state in multiple docker this can start to accumulate to a significant memory usage wasted. |
Hey @prgeor ,. we intergrated this PR and see that in some containers the fix is missing: Thanks |
@DavidZagury what is the normal limit in your system? What should the limit you would like? |
@@ -28,6 +28,10 @@ stdout_logfile=syslog | |||
stderr_logfile=syslog | |||
dependent_startup=true | |||
|
|||
[eventlistener:memmon] | |||
command=memmon -p rsyslogd=100MB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to capture the thresholds in a config file?
@prgeor , any update on the changes and next step? |
…der supervisord
Why I did it
Superlance plugins are useful to monitor and control process that run under supervisord inside a docker/container
Rsyslog has a known memory leak. The supervisord plugin superlance provides means to restart rsyslogd if memory increases beyond a threshold
Work item tracking
How I did it
How to verify it
Which release branch to backport (provide reason below if selected)
Tested branch (Please provide the tested image version)
Description for the changelog
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)