Bug 971199 - oo-admin-move throws undefined method 'categories' exception
Summary: oo-admin-move throws undefined method 'categories' exception
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Pod
Version: 2.x
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Ravi Sankar
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-06 01:17 UTC by Thomas Wiest
Modified: 2015-05-15 00:17 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-06-24 14:51:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Thomas Wiest 2013-06-06 01:17:04 UTC
Description of problem:
While trying to move a gear in PROD, I got this error:

# time oo-admin-move --change_district --gear_uuid 51ae7dc4e0b8cd673c00025a -i ex-lg-node10.prod.rhcloud.com
URL: http://REDACTED.rhcloud.com
Login: REDACTED
App UUID: 51ae792fe0b8cdddf2000177
Gear UUID: 51ae7dc4e0b8cd673c00025a
DEBUG: Source district uuid: 6dc28552f9e24537a4dbec6531fc7c72
DEBUG: Destination district uuid: 51313748e0b8cd67d4000001
/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:2038:in `block in get_app_status': undefined method `categories' for nil:NilClass (NoMethodError)
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:2036:in `each'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:2036:in `get_app_status'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:1772:in `move_gear'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:1744:in `block in move_gear_secure'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-controller-1.9.13/app/models/application.rb:1280:in `run_in_application_lock'
	from /opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-msg-broker-mcollective-1.9.9/lib/openshift/mcollective_application_container_proxy.rb:1743:in `move_gear_secure'
	from /usr/sbin/oo-admin-move:112:in `<main>'

real	0m9.618s
user	0m7.259s
sys	0m1.834s



Version-Release number of selected component (if applicable):
openshift-origin-broker-util-1.9.7-1.el6oso.noarch


How reproducible:
unsure

Steps to Reproduce:
1. unknown, happened in PROD


Actual results:
Exception


Expected results:
Gear should be moved

Comment 1 Ravi Sankar 2013-06-17 16:39:49 UTC
Fixed in https://github.com/openshift/origin-server/pull/2866

Comment 2 openshift-github-bot 2013-06-17 21:30:04 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/051a59ab2befe2b6d0f3227c4749bfd6502c4c54
Bug 971199 - Need to pass application object to CartridgeCache.find_cartridge method in mcollective_application_container_proxy.rb

Comment 3 zhaozhanqi 2013-06-18 07:42:44 UTC
Tested this issue on devenv_3373, it has been fixed


oo-admin-move --gear_uuid 709416623232455798685696 -i ip-10-244-145-57 --change_district
URL: http://setherpad-zqd.dev.rhcloud.com
Login: zzhao
App UUID: 51bfd31cb21f7fba28000141
Gear UUID: 51bfd379b21f7fba28000163
DEBUG: Source district uuid: e64fc0fcd7be11e2a27522000a9bdae1
DEBUG: Destination district uuid: 51bff9ffb21f7f39f7000001
DEBUG: Getting existing app 'setherpad' status before moving
DEBUG: Gear component 'nodejs-0.6' was running
DEBUG: Stopping existing app cartridge 'mongodb-2.2' before moving
DEBUG: Reserved uid '3528' on district: '51bff9ffb21f7f39f7000001'
DEBUG: Creating new account for gear '709416623232455798685696' on ip-10-244-145-57
DEBUG: Moving content for app 'setherpad', gear '709416623232455798685696' to ip-10-244-145-57
Identity added: /var/www/openshift/broker/config/keys/rsync_id_rsa (/var/www/openshift/broker/config/keys/rsync_id_rsa)
Agent pid 12080
unset SSH_AUTH_SOCK;
unset SSH_AGENT_PID;
echo Agent pid 12080 killed;
DEBUG: Moving system components for app 'setherpad', gear '709416623232455798685696' to ip-10-244-145-57
Identity added: /var/www/openshift/broker/config/keys/rsync_id_rsa (/var/www/openshift/broker/config/keys/rsync_id_rsa)
Agent pid 12108
unset SSH_AUTH_SOCK;
unset SSH_AGENT_PID;
echo Agent pid 12108 killed;
DEBUG: Starting cartridge 'mongodb-2.2' in 'setherpad' after move on ip-10-244-145-57
DEBUG: Fixing DNS and mongo for gear '709416623232455798685696' after move
DEBUG: Changing server identity of '709416623232455798685696' from 'ip-10-144-85-89' to 'ip-10-244-145-57'
DEBUG: Deconfiguring old app 'setherpad' on ip-10-144-85-89 after move
Successfully moved gear with uuid '709416623232455798685696' of app 'setherpad' from 'ip-10-144-85-89' to 'ip-10-244-145-57'


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