Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Component/s: Client (Ruby), Server
    • Labels:
      None
    • Environment:

      Description

      Steps:
      1.Build and Pushed an image to rhevm from aeolus
      2.Tried to lauch instance using it
      3.Instance went to "stopped'" state from "Pending"
      4.Observed error log in delta cloud
      5.No error message on conductor

      ------tail -f /var/log/deltacloud-core/mock.log -------

      thin server (localhost:3002) [deltacloud-mock][3469]: 127.0.0.1 - - [07/Mar/2012 05:55:24] "POST /api/instances/9c49dcec-7964-44e9-abaf-fa139276b570/start HTTP/1.1" 500 5838 0.5686
      thin server (localhost:3002) [deltacloud-mock][3469]: 127.0.0.1 - - [07/Mar/2012 05:55:24] "GET /api/instances/ HTTP/1.1" 404 18 0.0017
      thin server (localhost:3002) [deltacloud-mock][3469]: [NO HANDLED] RHEVM::RHEVMBackendException: Cannot run VM. There are no available running Hosts with sufficient memory in VM's Cluster .
      /usr/share/deltacloud-core/lib/deltacloud/drivers/rhevm/rhevm_client.rb:89:in `vm_action'
      /usr/share/deltacloud-core/lib/deltacloud/drivers/rhevm/rhevm_driver.rb:157:in `start_instance'
      /usr/share/deltacloud-core/lib/deltacloud/base_driver/exceptions.rb:151:in `call'
      /usr/share/deltacloud-core/lib/deltacloud/base_driver/exceptions.rb:151:in `safely'
      /usr/share/deltacloud-core/lib/deltacloud/drivers/rhevm/rhevm_driver.rb:156:in `start_instance'
      /usr/share/deltacloud-core/lib/deltacloud/helpers/application_helper.rb:128:in `send'
      /usr/share/deltacloud-core/lib/deltacloud/helpers/application_helper.rb:128:in `instance_action'
      /usr/share/deltacloud-core/lib/deltacloud/server.rb:523
      /usr/share/deltacloud-core/lib/sinatra/rabbit.rb:125:in `instance_eval'
      /usr/share/deltacloud-core/lib/sinatra/rabbit.rb:125:in `POST /api/instances/:id/start'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:1151:in `call'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:1151:in `compile!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:724:in `instance_eval'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:724:in `route_eval'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:708:in `route!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:758:in `process_route'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:755:in `catch'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:755:in `process_route'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:707:in `route!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:706:in `each'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:706:in `route!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:843:in `dispatch!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:644:in `call!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:808:in `instance_eval'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:808:in `invoke'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:808:in `catch'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:808:in `invoke'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:644:in `call!'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:629:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_syslog.rb:48:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_date.rb:31:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_accept.rb:149:in `call'
      /usr/lib/ruby/gems/1.8/gems/rack-1.3.0/lib/rack/head.rb:9:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_driver_select.rb:45:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_matrix_params.rb:106:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_runtime.rb:36:in `call'
      /usr/share/deltacloud-core/lib/sinatra/rack_etag.rb:41:in `call'
      /usr/lib/ruby/gems/1.8/gems/rack-accept-0.4.3/lib/rack/accept/context.rb:22:in `call'
      /usr/lib/ruby/gems/1.8/gems/rack-1.3.0/lib/rack/head.rb:9:in `call'
      /usr/lib/ruby/gems/1.8/gems/rack-1.3.0/lib/rack/methodoverride.rb:24:in `call'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:1272:in `call'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:1303:in `synchronize'
      /usr/lib/ruby/gems/1.8/gems/sinatra-1.2.6/lib/sinatra/base.rb:1272:in `call'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/connection.rb:84:in `pre_process'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/connection.rb:82:in `catch'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/connection.rb:82:in `pre_process'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1060:in `call'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1060:in `spawn_threadpool'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1057:in `initialize'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1057:in `new'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1057:in `spawn_threadpool'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:1049:in `defer'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/connection.rb:54:in `process'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/connection.rb:42:in `receive_data'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run_machine'
      /usr/lib/ruby/gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/backends/base.rb:61:in `start'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/server.rb:159:in `start'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/controllers/controller.rb:86:in `start'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/runner.rb:185:in `send'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/runner.rb:185:in `run_command'
      /usr/lib/ruby/gems/1.8/gems/thin-1.2.11/lib/thin/runner.rb:151:in `run!'
      /usr/share/deltacloud-core/bin/deltacloudd:235
      /usr/bin/deltacloudd:5:in `load'
      /usr/bin/deltacloudd:5

        Activity

        Hide
        Rehana Raj added a comment -
        Show
        Rehana Raj added a comment - Bugzilla id : https://bugzilla.redhat.com/show_bug.cgi?id=800852 for this issue
        Hide
        Michal Fojtik added a comment -

        commit 54a3b7af08e5e5c23f276f230e81f1d50a0be799
        Author: Michal Fojtik <mfojtik@redhat.com>
        Date: Thu Mar 8 13:35:40 2012 +0100

        RHEV-M: Report not memory available as 502 (Backend error) (DTACLOUD-154)

        diff --git a/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb b/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
        index dfe77b3..b350071 100644
        — a/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
        +++ b/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
        @@ -335,7 +335,7 @@ class RHEVMDriver < Deltacloud::BaseDriver
        status 501
        end

        • on /(InternalServerError|nodename nor servname provided)/ do
          + on /(InternalServerError|nodename nor servname provided|no available running Hosts)/ do
          status 502
          end

        Deltacloud should now report this error as 502 (Backend provider error) and this error should be properly captured
        by our exception handling system. Client should get correct XML message in return.

        Show
        Michal Fojtik added a comment - commit 54a3b7af08e5e5c23f276f230e81f1d50a0be799 Author: Michal Fojtik <mfojtik@redhat.com> Date: Thu Mar 8 13:35:40 2012 +0100 RHEV-M: Report not memory available as 502 (Backend error) ( DTACLOUD-154 ) diff --git a/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb b/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb index dfe77b3..b350071 100644 — a/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb +++ b/server/lib/deltacloud/drivers/rhevm/rhevm_driver.rb @@ -335,7 +335,7 @@ class RHEVMDriver < Deltacloud::BaseDriver status 501 end on /(InternalServerError|nodename nor servname provided)/ do + on /(InternalServerError|nodename nor servname provided|no available running Hosts)/ do status 502 end Deltacloud should now report this error as 502 (Backend provider error) and this error should be properly captured by our exception handling system. Client should get correct XML message in return.
        Hide
        Ronelle Landy added a comment -

        Verified that a 502 error is now thrown (and handled). Copying API output from trying to start a VM with 16 vcpus in rhevm:

        502 - Backend Server Error

        Cannot run VM. There are no available running Hosts with sufficient memory in VM's Cluster .

        Server message
        Deltacloud::ExceptionHandler::ProviderError - Cannot run VM. There are no available running Hosts with sufficient memory in VM's Cluster .

        Show
        Ronelle Landy added a comment - Verified that a 502 error is now thrown (and handled). Copying API output from trying to start a VM with 16 vcpus in rhevm: 502 - Backend Server Error Cannot run VM. There are no available running Hosts with sufficient memory in VM's Cluster . Server message Deltacloud::ExceptionHandler::ProviderError - Cannot run VM. There are no available running Hosts with sufficient memory in VM's Cluster .

          People

          • Assignee:
            Michal Fojtik
            Reporter:
            Rehana Raj
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development