-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/52261/#review150409
-----------------------------------------------------------


Ship it!




Ship It!

- Vitalyi Brodetskyi


On Вер. 26, 2016, 3:53 після полудня, Andrew Onischuk wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/52261/
> -----------------------------------------------------------
> 
> (Updated Вер. 26, 2016, 3:53 після полудня)
> 
> 
> Review request for Ambari and Vitalyi Brodetskyi.
> 
> 
> Bugs: AMBARI-18464
>     https://issues.apache.org/jira/browse/AMBARI-18464
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Python's `Popen` constructor takes an optional argument called `close_fds`
> which instructs Python to close all open file descriptors except for pipe,
> stdout, and stderr. However, Python's logic chooses to iterate over all
> possible open handles, not just those which are actually open.
> 
>   * With my `ulimit -n 1024`, `Popen` was taking ~2ms
>   * With my `ulimit -n 1000000`, `Popen` was taking ~150ms
> 
> That's an increase of 7400%, and all I did was increase my ulimit. The number
> of FDs opened was consistent.
> 
> In some environments, this `Popen` call can take between 6 and 60 seconds per
> call. This leads to a problem where status commands cannot be drained fast
> enough and results in the agent not responding to heartbeats and not running
> commands.
> 
> This Jira serves two purposes:
> 
>   * Investigate our use of `close_fds` and determine if it's correct (or at 
> least needs to be parameterized as a configuration option.
>   * Provide a host check warning for the ulimit being too high.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/alerts.json 9cffff5 
>   ambari-server/src/main/resources/host_scripts/alert_ulimit.py PRE-CREATION 
>   ambari-server/src/test/python/host_scripts/TestAlertUlimit.py PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/52261/diff/
> 
> 
> Testing
> -------
> 
> mvn clean test
> 
> 
> Thanks,
> 
> Andrew Onischuk
> 
>

Reply via email to