Bug 1163406 - The app dns will not be registered to the 2nd haproxy gear's node
Summary: The app dns will not be registered to the 2nd haproxy gear's node
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Containers
Version: 2.2.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ---
: ---
Assignee: Brenton Leanhardt
QA Contact: libra bugs
URL:
Whiteboard:
Depends On: 1161072
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-11-12 16:16 UTC by Brenton Leanhardt
Modified: 2014-12-10 13:25 UTC (History)
11 users (show)

Fixed In Version: rubygem-openshift-origin-node-1.32.3.1-1, rubygem-openshift-origin-frontend-apache-vhost-0.11.3.1-1, openshift-origin-node-util-1.31.3.1-1
Doc Type: Bug Fix
Doc Text:
Apache vhost definitions for high-availability applications were not created on the second node front end. Requests to the second node host would not be routed to the application, resulting in 404 errors. This bug fix updates the Apache vhost plug-in to ensure definitions are now created for high-availability applications on the second node front end. As a result, requests to the second node host are now routed properly to the application.
Clone Of: 1161072
Environment:
Last Closed: 2014-12-10 13:25:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1979 0 normal SHIPPED_LIVE Red Hat OpenShift Enterprise 2.2.2 bug fix and enhancement update 2014-12-10 18:23:46 UTC

Description Brenton Leanhardt 2014-11-12 16:16:07 UTC
+++ This bug was initially created as a clone of Bug #1161072 +++

Description of problem:
Create HA app on a multinode env. Add the node ip of the 2nd haproxy gear to /etc/hosts with the app dns.

When trying to visit the app dns, it will return 404 page. The app dns was not registered to the node frontend.

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

How reproducible:
always

Steps to Reproduce:
1. Setup multinode env
2. Create Scalable app on it and make it HA
3. Add the node ip of the 2nd haproxy gear and app dns to /etc/hosts
4. Visit the app dns.

Actual results:
It will return 404 page.

Expected results:
Should show the app home page when visiting the app dns which point to the 2nd haproxy gear's node.

Additional info:
Visit the app alias will not hit this problem.

# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6


54.81.35.75 php541s-bmengdevnew.dev.rhcloud.com foo.bmeng.com

# curl -Ik https://php541s-bmengdevnew.dev.rhcloud.com/
HTTP/1.1 404 Not Found
Date: Thu, 06 Nov 2014 15:39:55 GMT
Server: Apache/2.2.15 (Red Hat)
Vary: Accept-Encoding
Content-Type: text/html; charset=iso-8859-1

# curl -Ik https://foo.bmeng.com/
HTTP/1.1 200 OK
Date: Thu, 06 Nov 2014 15:40:21 GMT
Server: Apache/2.2.15 (Red Hat)
Content-Type: text/html; charset=UTF-8
Cache-control: private
Set-Cookie: GEAR=local-545b8bc7e4364b0094000004; path=/
Vary: Accept-Encoding
Accept-Ranges: none
ProxyTime: D=1307

--- Additional comment from Andy Goldstein on 2014-11-10 13:55:45 EST ---

I don't believe this is a bug. You would need a load balancer handling requests for the HA app URL (e.g. ha-myapp.yourdomain.rhcloud.com), and the load balancer would forward the requests to the app's haproxy gears.

--- Additional comment from Andy Goldstein on 2014-11-10 17:05:44 EST ---

Ignore my previous comment. I wasn't aware we had implemented this. This is probably something that broke with the switch from mod-rewrite to vhost. I'll keep investigating.

--- Additional comment from Andy Goldstein on 2014-11-12 11:13:43 EST ---

https://github.com/openshift/origin-server/pull/5954

Comment 2 Anping Li 2014-11-25 07:41:57 UTC
Verified and pass on new puddle puddle-2-2-2014-11-24.
Both the base DNS name and alias can be accessed through host IP pointing to different HA nodes.

Comment 4 errata-xmlrpc 2014-12-10 13:25:11 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2014-1979.html


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