Bug 963673 - [card #302] cannot snapshot ruby-1.8 with DB embedded after migration
[card #302] cannot snapshot ruby-1.8 with DB embedded after migration
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
All All
medium Severity medium
: ---
: ---
Assigned To: Mrunal Patel
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-16 07:10 EDT by zhaozhanqi
Modified: 2015-05-14 19:11 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-06-10 23:58:58 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 zhaozhanqi 2013-05-16 07:10:49 EDT
Description of problem:

cannot snapshot for ruby-1.8 with mysql,postgresql,mongodb embedded after migration


Version-Release number of selected component (if applicable):
Upgrading devenv-stage_353 to devenv_3232 and migrate

How reproducible:
always

Steps to Reproduce:
1. Launch devenv-stage_353
2. Create a scalableruby-1.8 app with mysql,postsql,mongo DB embedded
3. Add V1 marker to node
#touch /var/lib/openshift/.settings/v1_cartridge_format
4. scp -r ~/devenv-local and /etc/yum.repos.d/* from devenv_3232 instance to same location on devenv-stage_353 instance
5. yum update -y --enablerepo devenv-local
6. Run oo-admin-clear-pending-ops
7. Remove the v1 marker from the node
#rm -f /var/lib/openshift/.settings/v1_cartridge_format
8. Clear the broker cache
#rake tmp:clear
9. Restart the rhc-broker and mcollective
10. Run migrate-mongo-2.0.28 
11. Run rhc-admin-migrate --version 2.0.28
12. Snapshot save this app
rhc snapshot save zqruby18s
  
Actual results:

[redhat@localhost .ssh]$ rhc snapshot save zqruby18s
Pulling down a snapshot to zqruby18s.tar.gz...
Saving snapshot for secondary mysql-5.1 gear
Warning: Identity file 738960243772656015376384@738960243772656015376384-zqd.dev.rhcloud.com not accessible: No such file or directory.
Pseudo-terminal will not be allocated because stdin is not a terminal.
/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/utils/shell_exec.rb:129:in `block (2 levels) in oo_spawn': Shell command '/usr/bin/ssh -q -o 'BatchMode=yes' -o 'StrictHostKeyChecking=no' -i $OPENSHIFT_APP_SSH_KEY  738960243772656015376384@738960243772656015376384-zqd.dev.rhcloud.com 'snapshot' > mysql-5.1.tar.gz' returned an error. rc=255 (OpenShift::Utils::ShellExecutionException)
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/utils/shell_exec.rb:93:in `pipe'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/utils/shell_exec.rb:93:in `block in oo_spawn'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/utils/shell_exec.rb:92:in `pipe'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/utils/shell_exec.rb:92:in `oo_spawn'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/model/application_container.rb:651:in `block in handle_scalable_snapshot'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/model/application_container.rb:647:in `each'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/model/application_container.rb:647:in `handle_scalable_snapshot'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-node-1.9.1/lib/openshift-origin-node/model/application_container.rb:605:in `snapshot'
	from /usr/bin/gear:273:in `block (2 levels) in <main>'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/command.rb:180:in `call'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/command.rb:180:in `call'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/command.rb:155:in `run'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/runner.rb:385:in `run_active_command'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/runner.rb:62:in `run!'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/delegates.rb:11:in `run!'
	from /opt/rh/ruby193/root/usr/share/gems/gems/commander-4.0.3/lib/commander/import.rb:10:in `block in <top (required)>'
Error in trying to save snapshot. You can try to save manually by running:
ssh 51943e5e07b36a073b000001@zqruby18s-zqd.dev.rhcloud.com 'snapshot' > zqruby18s.tar.gz


Expected results:

no this error

Additional info:
Comment 1 Mrunal Patel 2013-05-16 16:44:20 EDT
https://github.com/openshift/li/pull/1401
Comment 2 Wei Sun 2013-05-17 04:47:34 EDT
Check this bug Upgraded from devenv-stage_353 to devenv_3236
It is fixed

Result:

[sunwei@dhcp-8-229 dev]$ rhc snapshot save r8mysql
Pulling down a snapshot to r8mysql.tar.gz...
-- Warning: Skipping the data of table mysql.event. Specify the --events option explicitly.
-- Warning: Skipping the data of table mysql.event. Specify the --events option explicitly.
Creating and sending tar.gz

RESULT:
Success

[sunwei@dhcp-8-229 dev]$ rhc snapshot restore r8mysql
Restoring from snapshot r8mysql.tar.gz...
Removing old git repo: ~/git/r8mysql.git/
Removing old data dir: ~/app-root/data/*
Restoring ~/git/927029129957750935126016.git and ~/app-root/data
MySQL restore attempted but no dump found!
/var/lib/openshift/927029129957750935126016/app-root/data//mysql_dump_snapshot.gz does not exist
MySQL already running
MySQL already running

RESULT:
Success

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