Bug 1160752 - Apache vhosts config missing, truncated
Summary: Apache vhosts config missing, truncated
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 2.x
Assignee: Jhon Honce
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks: 1161623
TreeView+ depends on / blocked
 
Reported: 2014-11-05 14:53 UTC by Sten Turpin
Modified: 2015-05-14 23:38 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1161623 (view as bug list)
Environment:
Last Closed: 2015-02-18 16:52:39 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Sten Turpin 2014-11-05 14:53:37 UTC
Description of problem: Since release 2.0.52, apache vhosts configurations are missing or incompleted. 


Version-Release number of selected component (if applicable): rubygem-openshift-origin-node-1.31.9-1.el6oso.noarch


How reproducible: sometimes


Steps to Reproduce:
Has been shown to happen on existing apps, possibly new apps. 

Actual results:
Gears return 404, 400, 302

Expected results:
Apache vhosts config should be complete and working

Additional info:
Attempted fix: 
find /etc/httpd/conf.d/openshift/ -type d -empty - match out that list, | xargs rhc-fix-missing-frontend -b
This fixed ~990 out of 10900+ empty apache dirs, didn't help with gears missing in /etc/httpd/conf.d/openshift/ or with incomplete vhost entries.

Comment 1 openshift-github-bot 2014-11-07 02:18:38 UTC
Commits pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/5b062cabb7ef125fc3743eea1b8fc2bbb17041c3
Bug 1160752 - Make apache-vhost more atomic

* Write one buffer to file rather than a number of write
* Truncate conf files rather than removing them to ease up httpd
  failures on restart
* Have watchman XXX plugin clean up "deleted" configurations

https://github.com/openshift/origin-server/commit/8710485cb06793ae67e4bac9aab349a41e0b19f2
Bug 1160752 - Add Watchman plugin to clean up vhost configurations

https://github.com/openshift/origin-server/commit/d2299d1c917227e9dad313ee467dda74fc88a9e7
Bug 1160752 - Make Watchman frontend cleanup period configurable

Comment 2 Meng Bo 2014-11-07 10:01:03 UTC
Do parallel creating/deleting and accessing the gears on node, will not cause httpd workers hang.

And after the watchman plugin introduced, the old httpd config files will not be deleted when the gear is deleting.
Set the time to two days past, the watchman will delete the configs automatically.

Move bug to verified.


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