Bug 1428016

Summary: [RFE] Tuning of passenger to avoid puppet DDOS
Product: Red Hat Satellite Reporter: Paul Armstrong <parmstro>
Component: InstallationAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED DUPLICATE QA Contact: Katello QA List <katello-qa-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.2.8CC: aperotti, bbuckingham, jcallaha, mmccune, rbost, stbenjam, wpinheir
Target Milestone: UnspecifiedKeywords: FutureFeature, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-03-24 20:44:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Paul Armstrong 2017-03-01 17:30:05 UTC
Description of problem:

When we upgraded to 6.2 and we removed the firewall rule from blocking clients to 8140 this took down our satellite server as too many processing requests from puppet clients took down the apache/passenger/puppet service(s). 

To fix the issue we've had to re-implement the firewall, stop puppet agent across all our servers, remove firewall rule, restart puppet in a delayed manner across the landscape.

A saner solution is to limit the number of connections Apache can service out of the window based upon Puppet facts for the server. Tuning the Apache server should happen as a part of the install as its a critical part to the ongoing operation of Puppet.

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

How reproducible:
All the time (until mitigating the problem)


Steps to Reproduce:
1. Block ports for upgrade or any other reason
2. Open ports...
3. Flood of Puppet requests.

Actual results:
Takes down apache/passenger/puppet

Expected results:
apache/passenger/puppet stay up - back off client systems...



Additional info:

Comment 2 Stephen Benjamin 2017-03-06 14:38:35 UTC
We ship since 6.2.7 I believe the adjusted Passenger settings that work in most large-ish environments.  If your environment is significantly larger, then those settings need further increasing. 

In 6.2.8, you can do this by editing /etc/foreman-installer/custom-hiera.yaml and doing:

---
apache::mod::passenger::passenger_max_pool_size: 12
apache::mod::passenger::passenger_max_instances_per_app: 6
apache::mod::passenger::passenger_max_request_queue_size: 250
apache::mod::passenger::passenger_stat_throttle_rate: 120

And changing whatever needs changing.  Those become persistent across upgrades (unlike editing passenger_extra.conf).


Is there some other action we need to take on this bug? We can't make the default 24/12, it's too much for a smaller Satellite instance.