Bug 1020770 - Unable to establish connection with scalable applications' db cartridges after migration
Unable to establish connection with scalable applications' db cartridges afte...
Product: OpenShift Online
Classification: Red Hat
Component: Containers (Show other bugs)
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Mrunal Patel
libra bugs
Depends On:
  Show dependency treegraph
Reported: 2013-10-18 05:20 EDT by Jianwei Hou
Modified: 2015-05-14 19:30 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2014-01-29 19:49:03 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Jianwei Hou 2013-10-18 05:20:57 EDT
Description of problem:
After node upgrade and migration, ssh into a scalable app and try to connect to its db cartridges(eg: mongo, postgresql), connection was refused.

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

How reproducible:

Steps to Reproduce:
1. Create scalable applications with db cartridges added on devenv-stage_496
2. Upgrade the devevn-stage ami to latest devenv ami, which is devenv_3912
3. Migrate all gears with oo-admin-upgrade
4. Pick one scalable app which has a db cartridge, ssh to this app and connect to db

Actual results:
After step 4: Unable to establish connection DBs from the application gear, however, connection from the db gears theirselves are allowed
[python27s-migration2.dev.rhcloud.com 5260cc189acd5f8bf10003d9]\> psql
psql: could not connect to server: Connection refused
	Is the server running on host "5260cc199acd5f0a8e000028-migration2.dev.rhcloud.com" and accepting
	TCP/IP connections on port 38171?
[python27s-migration2.dev.rhcloud.com 5260cc189acd5f8bf10003d9]\> mongo
MongoDB shell version: 2.4.6
connecting to: test
Fri Oct 18 04:38:37.109 Error: 18 { code: 18, ok: 0.0, errmsg: "auth fails" } at src/mongo/shell/db.js:228
exception: login failed

[python27s-migration2.dev.rhcloud.com 5260cc189acd5f8bf10003d9]\> ssh $OPENSHIFT_POSTGRESQL_DB_GEAR_UUID@$OPENSHIFT_POSTGRESQL_DB_GEAR_DNS


[5260cc199acd5f0a8e000028-migration2.dev.rhcloud.com 5260cc199acd5f0a8e000028]\> psql
psql (8.4.13)
Type "help" for help.


Expected results:
Should be able to connect to db gears from all gears of the application.

Additional info:
Comment 1 Mrunal Patel 2013-10-21 17:17:51 EDT
Comment 2 openshift-github-bot 2013-10-21 18:58:11 EDT
Commit pushed to master at https://github.com/openshift/li

Bug 1020770: rhc-app-comm/nat getting flushed due to iptables restart.
Comment 3 Jianwei Hou 2013-10-22 02:30:10 EDT
Verified on devenv_3925
After upgraded to 3925 and migrate, the problem is gone. the connections to DBs can be established successfully on scalable application gears.
Comment 4 Andrei Colta 2014-01-18 05:40:58 EST

I have the similar issue, it seems i can't auth on mongo gear under scalable app.

Sat Jan 18 05:39:23.556 Error: couldn't connect to server hostname:38066 at src/mongo/shell/mongo.js:147
exception: connect failed

Could you please help?

Thank you in advance.

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