Hide Forgot
Description of problem: met the error "OPENSHIFT_GEAR_NAME is missing!" when first time destroy the front-end connection for a gear Version-Release number of selected component (if applicable): devenv_3966 How reproducible: Always Steps to Reproduce: 1. create app 2. ssh into instance #cd /var/lib/openshift/<uuid>/.env/ #rm OPENSHIFT_GEAR_DNS OPENSHIFT_GEAR_NAME 3.run below cmd a).oo-cgroup-reclassify --with-all-containers b).oo-cgroup-enable --with-all-containers c).oo-cgroup-reclassify --with-container-uuid <uuid> d).oo-cgroup-enable --with-container-uuid <uuid> e).oo-devel-node frontend-destroy -c <uuid> f).oo-devel-node frontend-destroy -c <uuid> Actual results: step3 e). [root@ip-10-239-13-250 .env]# oo-devel-node frontend-destroy -c 5270d4114bdb8ee197000110 5270d4114bdb8ee197000110 is missing or not a valid gear: OPENSHIFT_GEAR_NAME is missing! f). [root@ip-10-239-13-250 .env]# oo-devel-node frontend-destroy -c 5270d4114bdb8ee197000110 5270d4114bdb8ee197000110 is missing or not a valid gear: OPENSHIFT_GEAR_NAME is missing! Expected results: should not fail when first time destroy the front-end connection for a gear will show the meassge when the second time run the command Additional info: get the infomation (should not fail when first time destroy the front-end connection for a gear ) from below bug : https://bugzilla.redhat.com/show_bug.cgi?id=982403
A recent change in ApplicationContainer prevents the FrontendHttpServer object from implementing its internal database to lookup information on broken gears. I'll provide a "purge" command which works around the lack of a working ApplicationContainer object.
Purge command added: https://github.com/openshift/origin-server/pull/4082 Ex: oo-devel-node frontend-purge -c rmtest-rmillner0165.dev.rhcloud.com oo-devel-node frontend-purge -c 5278180c878c9c4046000001
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/2ecbc8d7ea202dbf4586c4848bd7189d2ef88027 Bug 1024721 - Add purge functionality to the frontend plugins.
Commit pushed to master at https://github.com/openshift/li https://github.com/openshift/li/commit/54e30ef3625b122dd0b820778a2f5e6f75254f81 Bug 1024721 - use the purge functionality in the frontends.
1. For new apps on stg, all dbs can be connected normally. 2. For old apps on stg (after migration), seems some of them still have the problem: [perlsdbjks-dystg.stg.rhcloud.com 52735fd1dbd93c7f6900001c]\> mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 Server version: 5.1.69 Source distribution Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> exit Bye [perlsdbjks-dystg.stg.rhcloud.com 52735fd1dbd93c7f6900001c]\> psql psql: could not connect to server: Connection refused Is the server running on host "52735fd1dbd93c7f6900002c-dystg.stg.rhcloud.com" and accepting TCP/IP connections on port 47036? [perlsdbjks-dystg.stg.rhcloud.com 52735fd1dbd93c7f6900001c]\> mongo MongoDB shell version: 2.4.6 connecting to: 52735fd1dbd93c7f69000038-dystg.stg.rhcloud.com:39921/admin Mon Nov 4 21:22:53.149 Error: couldn't connect to server 52735fd1dbd93c7f69000038-dystg.stg.rhcloud.com:39921 at src/mongo/shell/mongo.js:147 exception: connect failed
Sorry for adding the wrong comment by mistake in #C5. Pls. ignore it.
Test on devenv_3688 Can purge a broken gear from the Frontend Http configuration by using oo-devel-node frontend-purge -c <UUID> or oo-devel-node frontend-purge -c $app-url move bug to verified.