Description of problem: Can't do thread dump success for ruby1.8 and ruby1.9 application Version-Release number of selected component (if applicable): devenv_1912 cartridge-ruby-1.9-0.3.3-1.git.0.e10fc0f.el6.noarch cartridge-ruby-1.8-0.96.3-1.git.0.bb9e28c.el6.noarch How reproducible: always Steps to Reproduce: 1.Create ruby1.8 or ruby-1.9 app 2.Then use: rhc app threaddump -a ruby 3. Actual results: [root@localhost mytest]# rhc app threaddump -a qruby18 Password: RESULT: 2f41a10a7036410ba2c5b07accdf7369 Expected results: Could show like RESULT: Success The thread dump file will be available via: rhc app tail -a qjboss -f qjboss/jbossas-7/standalone/tmp/qjboss.log -o '-n 250' Additional info: log from development.log Started POST "/broker/cartridge" for 203.114.244.88 at Thu Jul 26 00:40:50 -0400 2012 Processing by LegacyBrokerController#cartridge_post as Parameters: {"json_data"=>"{\"api\":\"1.1.3\",\"action\":\"threaddump\",\"rhlogin\":\"qgong\",\"app_name\":\"qsruby19\"}", "password"=>"[FILTERED]"} User-Agent = '' MongoDataStore.find(CloudUser, qgong, qgong) DEBUG: rpc_exec_direct: rpc_client=#<MCollective::RPC::Client:0x7f973100cf10> DEBUG: rpc_client.custom_request('cartridge_do', {:action=>"threaddump", :cartridge=>"ruby-1.9", :args=>"'qsruby19' 'qgong6' '17c6263a074d45b1a73fd0e2d672d893'"}, @id, {'identity' => @id}) DEBUG: [#<MCollective::RPC::Result:0x7f97313cf4b8 @action="cartridge_do", @results={:statuscode=>0, :statusmsg=>"OK", :data=>{:exitcode=>0, :output=>"/usr/libexec/stickshift/cartridges/ruby-1.9/info/bin/threaddump.sh: line 17: [5142: command not found\n/usr/libexec/stickshift/cartridges/ruby-1.9/info/hooks/threaddump: line 39: [17c6263a074d45b1a73fd0e2d672d893: command not found\nCLIENT_RESULT: 17c6263a074d45b1a73fd0e2d672d893\n17c6263a074d45b1a73fd0e2d672d893\n"}, :sender=>"ip-10-28-203-164"}, @agent="stickshift">] DEBUG: Cartridge command ruby-1.9::threaddump exitcode = 0 [REQ_ID=67057b0dc1e143f9b4d19efce0910870] ACTION=LEGACY_CARTRIDGE_POST Processed event threaddump for application qsruby19 Completed 200 OK in 776ms (Views: 1.8ms) jbossas and jbosseap work well.
pull request in process
Pull requests: https://github.com/openshift/li/pull/137 https://github.com/openshift/crankcase/pull/295
Pull requests accepted.
Reopen it on devenv_1920, Since the thread dump still can't work, now it works as below, I have accessed the app, but still show thread dump error. [root@localhost non_scalable]# rhc app status -a redmine Password: RESULT: Total Accesses: 16 Total kBytes: 317 Uptime: 3071 ReqPerSec: .00521003 BytesPerSec: 105.701 BytesPerReq: 20288 BusyWorkers: 1 IdleWorkers: 1 Scoreboard: _W... [root@localhost non_scalable]# rhc app threaddump -a redmine Password: RESULT: Application is inactive. Ruby/Rack applications must be accessed by their URL (http://redmine-qgong1.dev.rhcloud.com) before you can take a thread dump.
This error is saying you must hit your app's url (http://redmine-qgong1.dev.rhcloud.com) before you can thread dump it. This is required for the threads to be running for your application so there is something to threaddump. I tried an example and this works fine. If there is another issue and I am missing it please reopen.
This error pass on devenv_1923, but didn't pass on INT, so let this bug wait for new patch to INT. Now in INT: [root@localhost mytest]# rhc app threaddump -a q11ruby19 1Password: ****** RESULT: 82e8862b47db4897855c760a0be95961
This issue is still reproduced with current stg env, but it works well with devenv-stage_228. Here's the result for your reference: On stage: (This issue is still reproduced.) # rhc app threaddump -a ruby19 -p redhat RESULT: ddd85cf716194cf990c60292f59c7704 On devenv-stage_228: (This issue doesn't exist) #rhc app threaddump -a ruby19 -p redhat RESULT: Success The thread dump file will be available via: rhc app tail -a ruby19 -f ruby19/logs/error_log-20120803-000000-EST -o '-n 250' So assign it back. Thanks.
The namespace.init file was being maintained separate. Had to provide instructions via the release ticket to update the file.
The fix has been pushed to both INT and STG. Please test it in both. The fix is part of the release ticket and so will be pushed when we do the PROD push.
Verified on INT and STG INT: [root@localhost mytest]# rhc app threaddump -a qruby18 Password: ****** RESULT: Success The thread dump file will be available via: rhc app tail -a qruby18 -f qruby18/logs/error_log-20120806-000000-EST -o '-n 250' STG: [root@localhost rhc]# rhc app threaddump -a qruby19 Password: ****** RESULT: Success The thread dump file will be available via: rhc app tail -a qruby19 -f qruby19/logs/error_log-20120806-000000-EST -o '-n 250'