Comment 4 for bug 1770726

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/queens)

Reviewed: https://review.openstack.org/568642
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=177ad2dcfc19e891994c69c678feda4190547e3f
Submitter: Zuul
Branch: stable/queens

commit 177ad2dcfc19e891994c69c678feda4190547e3f
Author: Matt Riedemann <email address hidden>
Date: Fri May 11 14:44:47 2018 -0400

    Don't reschedule on RequestedVRamTooHigh errors

    The libvirt driver validates the hw_video_ram image property,
    if specified, and the flavor extra spec "hw_video:ram_max_mb"
    is set. If validation fails, the libvirt driver raises
    RequestedVRamTooHigh which is not handled explicitly in
    ComputeManager._build_and_run_instance so it will result in
    a RescheduledException to another compute to retry the spawn
    but that will always fail because this isn't something that
    is per-compute host.

    This change adds the error handling in _build_and_run_instance
    so that we'll fail and abort the build and not reschedule.

    Long-term, this validation should be moved into the API code
    since it's not specific to a compute host and would be user
    error that should result in a 400 response.

    Change-Id: I93b409ca2b7b36400759ee9d2cd5b71c6df186ab
    Partial-Bug: #1770726
    (cherry picked from commit cd53a181be22291e6f9be1430cab12ba1f381b8a)