Bug 1030305 - 'rhc app show --state/--gear' shows db gear stop after restore snapshot for scalable app
'rhc app show --state/--gear' shows db gear stop after restore snapshot for s...
Status: CLOSED UPSTREAM
Product: OpenShift Online
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Vincent Batts
libra bugs
:
: 1057950 1064040 1071236 (view as bug list)
Depends On:
Blocks: 1062621
  Show dependency treegraph
 
Reported: 2013-11-14 05:28 EST by Lei Zhang
Modified: 2015-05-14 19:32 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1062621 (view as bug list)
Environment:
Last Closed: 2014-01-20 18:02:11 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)
status of the cartridges from the web console (39.30 KB, image/png)
2014-01-17 09:53 EST, Vincent Batts
no flags Details

  None (edit)
Description Lei Zhang 2013-11-14 05:28:05 EST
Description of problem:
Given one scalable app create(e.g., myjbossews20s), embed some db and do save snapshot, and then restore snapshot, found 'rhc app show --state/--gear' show the state of db gear stop not started, but 'rhc cartridge status' shows the status of db gear running. 


+ tmp=/var/lib/openshift/528495f36cec0eb09c00085c/jbossews//tmp
+ '[' -d /var/lib/openshift/528495f36cec0eb09c00085c/jbossews//tmp ']'
+ for d in '$tmp/*'
+ '[' -d '/var/lib/openshift/528495f36cec0eb09c00085c/jbossews//tmp/*' ']'
++ ls /var/lib/openshift/528495f36cec0eb09c00085c/app-root/runtime/repo//webapps
+ '[' '' ']'
Activation status: success
RESULT:
Success
[lijun@ray Work]$ rhc app show --gear -a myjbossews20s
ID                       State   Cartridges               Size  SSH URL
------------------------ ------- ------------------------ ----- ---------------------------------------------------------------------
528495f36cec0eb09c000860 stopped mysql-5.1                small 528495f36cec0eb09c000860@528495f36cec0eb09c000860-ray.int.rhcloud.com
528495f36cec0eb09c00086c stopped mongodb-2.2              small 528495f36cec0eb09c00086c@528495f36cec0eb09c00086c-ray.int.rhcloud.com
528495f36cec0eb09c00085c started jbossews-2.0 haproxy-1.4 small 528495f36cec0eb09c00085c@myjbossews20s-ray.int.rhcloud.com
[lijun@ray Work]$ rhc app show --state -a myjbossews20s
Cartridge mysql-5.1 is stopped
Cartridge mongodb-2.2 is stopped
Cartridge jbossews-2.0, haproxy-1.4 is started
[lijun@ray Work]$ rhc cartridge status  -a myjbossews20s -c mysql-5.1
RESULT:
MySQL is running
[lijun@ray Work]$ rhc cartridge status  -a myjbossews20s -c mongodb-2.2
RESULT:
MongoDB is running

Version-Release number of selected component (if applicable):
INT(devenv_4030)
devenv_4031

How reproducible:
always

Steps to Reproduce:
1.create one scalable app
#rhc app create myjbossews20s jbossews-2.0 -s mysql-5.1 mongodb-2.2
2.save snapshot
#rhc snapshot save myjbossews20s
3.restore snapshot and check the gear status 
#rhc snapshot restore -a myjbossews20s -f myjbossews20s.tar.gz
#rhc app show --gear -a myjbossews20s

Actual results:
'rhc app show --state/--gear' shows db gear stop

Expected results:
'rhc app show --state/--gear' should show db gear started

Additional info:
Comment 1 Vincent Batts 2014-01-17 09:53:36 EST
Created attachment 851649 [details]
status of the cartridges from the web console

so the web console also shows that they're stopped.

Though I see the pids running on the node itself.

1000     19688     1  0 Jan16 ?        00:00:00 /bin/bash /var/lib/openshift/658642806346601025503232/mysql/bin/control post-restore
1000     19693 19688  0 Jan16 ?        00:00:00 /bin/sh /usr/bin/mysqld_safe --defaults-file=/var/lib/openshift/658642806346601025503232/mysql//conf/my.cnf
1000     19824 19693  0 Jan16 ?        00:00:22 /usr/libexec/mysqld --defaults-file=/var/lib/openshift/658642806346601025503232/mysql//conf/my.cnf --basedir=/usr --datadir=/var/lib/openshift/658642806346601025503232/mysql/data/ --log-error=/var/lib/openshift/658642806346601025503232/mysql//log/mysql_error.log --pid-file=/var/lib/openshift/658642806346601025503232/mysql/pid/mysql.pid --socket=/var/lib/openshift/658642806346601025503232/mysql//socket/mysql.sock
1001     19978     1  0 Jan16 ?        00:01:46 /usr/bin/mongod --auth -f /var/lib/openshift/3087259a7f0611e38d18fe428b6bd8e1/mongodb//conf/mongodb.conf run
Comment 2 Jhon Honce 2014-01-20 18:02:11 EST
https://trello.com/c/SMPN5PNY
Comment 3 Jhon Honce 2014-01-27 11:53:40 EST
*** Bug 1057950 has been marked as a duplicate of this bug. ***
Comment 4 Jhon Honce 2014-03-03 10:42:53 EST
*** Bug 1064040 has been marked as a duplicate of this bug. ***
Comment 5 Jhon Honce 2014-03-03 10:53:39 EST
*** Bug 1071236 has been marked as a duplicate of this bug. ***
Comment 6 openshift-github-bot 2014-03-14 10:40:50 EDT
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/01feb57a151b8829d6900efb2b8d1b05a6b78fdf
Bug 1030305 - 'rhc app show --state/--gear' shows db gear stop after
restore snapshot for scalable app

Given one scalable app create(e.g., myjbossews20s), embed some db and do
save snapshot, and then restore snapshot, found 'rhc app show
--state/--gear' show the state of db gear stop not started, but 'rhc
cartridge status' shows the status of db gear running.
Comment 7 openshift-github-bot 2014-04-01 21:23:46 EDT
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/6fd30130f9e969e43be8c69ba3c5ef577854737f
Revert "Card origin_cartridge_133 - Maintain application state across snapshot/restore"

This reverts commit 2b90c5fcf9cee4ddf95dece0546970d7da13780e.

Revert "Bug 1030305 - 'rhc app show --state/--gear' shows db gear stop after"

This reverts commit 01feb57a151b8829d6900efb2b8d1b05a6b78fdf.

Conflicts:
	controller/test/cucumber/step_definitions/application_steps.rb

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