Bug 1010461 - nodejs supervisor poll interval is too short
Summary: nodejs supervisor poll interval is too short
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers   
(Show other bugs)
Version: 2.x
Hardware: Unspecified Unspecified
Target Milestone: ---
: ---
Assignee: Jhon Honce
QA Contact: libra bugs
Depends On:
TreeView+ depends on / blocked
Reported: 2013-09-20 20:04 UTC by Andy Grimm
Modified: 2018-12-03 20:00 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-10-17 13:30:09 UTC
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Bugzilla 1010464 None None None Never

Description Andy Grimm 2013-09-20 20:04:20 UTC
Description of problem:

The default poll interval in versions of node.js supervisor prior to 0.5.3 is known to be too short and cause performance issues.  nodejs010 SCL contains 0.5.2, and nodejs 0.6 has an even older version.  There is a "-p" option to change the interval.  "-p 1000" (or higher) is recommended.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. Create a node.js app on Openshift with lots of js files in the repo.
2. Start the app
3. Watch supervisor eat CPU

Actual results:

Unacceptable CPU usage

Expected results:

Reasonably low overhead

Additional info:

strace showed over 1000 futex calls per second in an app with a couple thousand files.

Upstream issue:


Comment 1 openshift-github-bot 2013-09-25 06:20:14 UTC
Commit pushed to master at https://github.com/openshift/origin-server

Bug 1010461 - Increase supervisor poll_interval

* Increase default supervisor poll_interval to reduce resource usage

Comment 2 Meng Bo 2013-09-26 12:35:15 UTC
Verified on devenv_3833,

To compare, do the same test on devenv-stage_478,

1. Create nodejs-0.10 app
2. SSH login to the app
3. Copy the server.js file to <random>.js about 5000 times under app-repo
4. Restart the gear
5. Use top to check the cpu usage of the supervisor process

On stage ami, it will use up to 99% cpu, and keep in about 60% for a while and then down to 30%.

On devenv_3833, it will use up to 40% cpu, and will go down in a short time with about 5%-10% usage.

Move bug to verified.

Note You need to log in before you can comment on or make changes to this bug.