Bug 839211 - Failed created app can not be destroyed and user can not create app any more
Failed created app can not be destroyed and user can not create app any more
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Pod (Show other bugs)
1.x
Unspecified Unspecified
high Severity medium
: ---
: ---
Assigned To: Ravi Sankar
libra bugs
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-11 04:54 EDT by Xiaoli Tian
Modified: 2012-07-13 19:43 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-07-13 19:43:52 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)
failed app failed to destroy broker log (39.38 KB, text/plain)
2012-07-11 04:55 EDT, Xiaoli Tian
no flags Details
Manual destroy failed app log (39.74 KB, text/plain)
2012-07-11 04:58 EDT, Xiaoli Tian
no flags Details
Failed to create app again broker log (79.50 KB, text/plain)
2012-07-11 05:00 EDT, Xiaoli Tian
no flags Details

  None (edit)
Description Xiaoli Tian 2012-07-11 04:54:43 EDT
Description of problem:
If the app creating failed, it still shows in rhc domain show, while destorying it, it shows:
#rhc app destroy -a scalejboss1 -l xtian+t100@redhat.com -p1
RSULT:
Could not destroy all gears of application.

When try to create another new app, it shows:
#rhc app create -a scalejboss2  -t jbossas-7 -s  -l xtian+t100@redhat.com -p 1 --enable-jenkins  

Found existing Jenkins application: jenkins
Creating application: scalejboss2 in domainxdev001
/usr/local/share/gems/gems/rhc-0.95.12/lib/rhc-common.rb:519:in `create_app': undefined method `uuid' for []:Array (NoMethodError)
	from /usr/local/share/gems/gems/rhc-0.95.12/bin/rhc-app:230:in `create_app'
	from /usr/local/share/gems/gems/rhc-0.95.12/bin/rhc-app:505:in `<top (required)>'
	from /usr/local/bin/rhc-app:23:in `load'
	from /usr/local/bin/rhc-app:23:in `<main>'



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

How reproducible:
Not always

Steps to Reproduce:
1.Remove the following file from your ~/.ssh/config if you have it 
Host *.dev.rhcloud.com
    IdentityFile ~/.ssh/id_rsa
    VerifyHostKeyDNS yes
    StrictHostKeyChecking no
    UserKnownHostsFile ~/.ssh/known_hosts

2.Remove ~/.ssh/known_hosts if it exists
3.Create an app but not type yes at once when it ask you if you want to continue:
[root@F17x64-openshift 711]# rhc app create -a scalejboss1 -l xtian+t100@redhat.com -p 123456  -t jbossas-7 -s 

Creating application: scalejboss1 in domainxdev001
Now your new domain name is being propagated worldwide (this might take a minute)...
    retry # 4 - Waiting for DNS: scalejboss1-domainxdev001.dev.rhcloud.com
The authenticity of host 'scalejboss1-domainxdev001.dev.rhcloud.com (107.22.138.212)' can't be established.
RSA key fingerprint is ad:2c:f7:ed:fc:cb:0f:ff:cb:73:f9:c7:15:96:da:b9.
Are you sure you want to continue connecting (yes/no)?

4. Wait for several minutes and type yes

5. Check your domain show, and server log:
it's listed in your domain, some error in broker log (see detail in attachment):

Consistency check failed.  Could not update application 'scalejboss1' for 'xtian+t100@redhat.com'
#<StickShift::UserException: Consistency check failed.  Could not update application 'scalejboss1' for 'xtian+t100@redhat.com'>

5. Try to destroy it   

#rhc app destroy -a scalejboss1 -l xtian+t100@redhat.com -p1
RSULT:
Could not destroy all gears of application.
Some log in broker:

Unable to clean up application on gear #<Gear:0x7f293c294b38> due to exception Unable to destroy gear on node
["/usr/lib/ruby/gems/1.8/gems/stickshift-controller-0.13.12/lib/stickshift-controller/app/models/gear.rb:69:in `destroy'"

6. Create new app for this user failed:


Expected results:
Failed created app could be destroyed at least, new app could be created as well

Additional info:
Comment 1 Xiaoli Tian 2012-07-11 04:55:54 EDT
Created attachment 597507 [details]
failed app failed to destroy broker log
Comment 2 Xiaoli Tian 2012-07-11 04:58:15 EDT
Created attachment 597509 [details]
Manual destroy failed app log
Comment 3 Xiaoli Tian 2012-07-11 05:00:56 EDT
Created attachment 597511 [details]
Failed to create app again broker log
Comment 4 Johnny Liu 2012-07-11 08:40:44 EDT
I also encouter this issue too.

Reproduce it easily, create a scalbe app, then destroy it.
Comment 5 Dan McPherson 2012-07-11 10:49:33 EDT
I haven't been able to recreate with the steps from comment 1 or comment 4.
Comment 6 Dan McPherson 2012-07-11 10:59:27 EDT
Rajat,  I can't recreate but have a feeling this is related to your changes.  Can you take a look.
Comment 7 Dan McPherson 2012-07-11 11:15:24 EDT
Actually it looks more like Ravi's changes.  I would like to talk about what's going on here.
Comment 8 Ravi Sankar 2012-07-11 17:25:32 EDT
Code changes for Bug#835176 caused this issue. Fixed in git rev. 870689373c3.
Comment 9 Johnny Liu 2012-07-12 03:13:32 EDT
Verified this bug on devenv-stage_223, try serveral times, all PASSed.

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