Bug 866416 - Failed to connect mysql after snapshot restored to a new created scalable app
Failed to connect mysql after snapshot restored to a new created scalable app
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Dan Mace
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-15 06:21 EDT by joycezhang
Modified: 2015-05-14 19:00 EDT (History)
2 users (show)

See Also:
Fixed In Version: devenv_2340+
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-11-06 13:48:15 EST
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 joycezhang 2012-10-15 06:21:37 EDT
Description of problem:
Mysql data couldn't be resotred to a new scalable jbossews app, it can't connect to mysql shell as below:
[myscalapp1-jingdev1.dev.rhcloud.com ~]\> mysql
ERROR 1130 (HY000): Host '127.0.254.129' is not allowed to connect to this MySQL server



Version-Release number of selected component (if applicable):
devenv_2327
rhc-0.99.5.gem

How reproducible:
always


Steps to Reproduce:
1.Create an scaling  jbossews  app
rhc app create -a app1 -t  jbossews-1.0  -s

2. Disable auto scaling by:
create new file $APP_Dir/.openshift/markers/disable_auto_scaling
cd $APP
touch .openshift/markers/disable_auto_scaling
git commit -a -m "disable_auto_scaling"
git push

3. Scale up by rest API

4. Add mysql to the app
#rhc cartridge add mysql-5.10 -a app1

5. Write some data to mysql

6. Snapshot save this app
#rhc snapshot save app1 -p xx

7. Delete this app
#rhc delete app app1 --confirm

8. Repeat step 1 to 4 to create a new scalable app with mysql added.

9. Restore snapshot
#rhc snapshot restore app1 -f ./app1.tar.gz

10. SSH into the app and check mysql data

  
Actual results:
It can't connect to mysql.


Expected results:
Mysql shell can be accessed, and data is restored.

Additional info:
1. It works well if snapshot restored to an existing scalable app.
2. It's also reproduced in other cartridges, like php-5.3.
Comment 1 Dan Mace 2012-10-16 18:07:17 EDT
Fix awaiting merge: https://github.com/openshift/origin-server/pull/691
Comment 2 Xiaoli Tian 2012-10-16 23:26:55 EDT
(In reply to comment #1)
> Fix awaiting merge: https://github.com/openshift/origin-server/pull/691

Above is merged in devenv-2340, move it to ON_QA to verify
Comment 3 joycezhang 2012-10-17 01:06:42 EDT
This bug has been verified on devenv_2340 with rhc-0.99.7.gem client. It's fixed. mysql can be accessed after the new created scalable app restored, and data is back as well. So mark it as Verified.Thanks.
Comment 4 Xiaoli Tian 2012-10-17 09:56:35 EDT
Move it to verified according to comment 3.

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