Bug 965373 - rhc-fix-stale-frontend doesn't remove stale entries from geardb.json
rhc-fix-stale-frontend doesn't remove stale entries from geardb.json
Status: CLOSED CURRENTRELEASE
Product: OpenShift Online
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Rob Millner
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-21 00:33 EDT by Thomas Wiest
Modified: 2015-05-14 19:19 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-06-11 00:07:02 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Thomas Wiest 2013-05-21 00:33:48 EDT
Description of problem:
On an ex-node in PROD, I got this error from oo-accept-node:

FAIL: httpd config references UUID without associated gear: '51916736e0b8cdff7c00085f'


I tried to fix it using rhc-fix-stale-frontend:

# rhc-fix-stale-frontend 51916736e0b8cdff7c00085f
Deleting names and any associated aliases from the frontend:
	51916736e0b8cdff7c00085f
Hit 'y' to continue, anything else to abort.
y
Deleting from ApacheDBNodes...
Deleting from ApacheDBAliases...
Deleting from ApacheDBIdler...
Deleting from ApacheDBSTS...
Deleting from NodeJSDBRoutes...
Deleting from GearDB...
Done


However, it did _not_ remove the entry from geardb.json:

# grep -l 51916736e0b8cdff7c00085f /etc/httpd/conf.d/openshift/*
/etc/httpd/conf.d/openshift/geardb.json
#


Note: I'm also still getting the same failure listed above from oo-accept-node.


Version-Release number of selected component (if applicable):
rhc-node-1.8.7-1.el6oso.x86_64


How reproducible:
Very if the node is left in geardb.json


Steps to Reproduce:
1. Unknown, found in PROD


Actual results:
The entry is left in geardb.json


Expected results:
rhc-fix-stale-frontend should clear the entry from all frontend configs.
Comment 1 Rob Millner 2013-05-22 13:30:25 EDT
Added code to resolve the UUID if its available in the gear database.

Pull request:
https://github.com/openshift/li/pull/1441

# ./rhc-fix-stale-frontend 138985f4c27411e2b44922000a904f83
Deleting names and any associated aliases from the frontend:
	rmt23-rmillner0105.dev.rhcloud.com
Hit 'y' to continue, anything else to abort.
y
Deleting from ApacheDBNodes...
Deleting from ApacheDBAliases...
Deleting from ApacheDBIdler...
Deleting from ApacheDBSTS...
Deleting from NodeJSDBRoutes...
Deleting from GearDB...
Done
[root@ip-10-144-79-131 ~]# grep 138985f4c27411e2b44922000a904f83 /etc/httpd/conf.d/openshift/*
[root@ip-10-144-79-131 ~]# grep rmt23-rmillner0105.dev.rhcloud.com /etc/httpd/conf.d/openshift/*
Comment 2 openshift-github-bot 2013-05-22 19:05:31 EDT
Commit pushed to master at https://github.com/openshift/li

https://github.com/openshift/li/commit/9e6e86982e0f0a59761cb4bb6e299df6b8e1313b
Bug 965373 - Attempt to resolve a UUID in the geardb.
Comment 3 Meng Bo 2013-05-23 05:40:41 EDT
Issue fixed on devenv_3262,

[root@ip-10-196-90-40 conf]# rhc-fix-stale-frontend 519dcb4265d9c901a400003d
Deleting names and any associated aliases from the frontend:
	perl1-bmeng1.dev.rhcloud.com
Hit 'y' to continue, anything else to abort.
y
Deleting from ApacheDBNodes...
Deleting from ApacheDBAliases...
Deleting from ApacheDBIdler...
Deleting from ApacheDBSTS...
Deleting from NodeJSDBRoutes...
Deleting from GearDB...
Done
[root@ip-10-196-90-40 conf]# grep 519dcb4265d9c901a400003d /etc/httpd/conf.d/openshift/*
[root@ip-10-196-90-40 conf]# grep perl1-bmeng1.dev.rhcloud.com /etc/httpd/conf.d/openshift/*

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