Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 916823

Summary: Shown wrong message in Status page when disable Intel/AMD virtuallization support in BIOS.
Product: [Retired] oVirt Reporter: haiyang,dong <hadong>
Component: ovirt-nodeAssignee: Fabian Deutsch <fdeutsch>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 3.2CC: acathrow, collura, cshao, gouyang, hadong, jboggs, leiwang, mgoldboi, ovirt-bugs, ovirt-maint, ycui
Target Milestone: ---   
Target Release: 3.4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: node
Fixed In Version: ovirt-node-3.0.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-03-31 12:29:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
attached Screenshot for RHEV-M Configuration Page none

Description haiyang,dong 2013-03-01 03:23:46 UTC
Created attachment 704051 [details]
attached Screenshot for RHEV-M Configuration Page

Description of problem:
Shown wrong message in Status page when disable Intel/AMD virtuallization support in BIOS.

Maybe rewrite these functions "hardware_is_available" and "hardware_is_enabled" into 
follow can resolve this issue:
def hardware_is_available():
    """Determins if virtualization hardware is available.

    Returns:
        True if there is hardware virtualization hardware available
    """
    has_virtualization = False

    with open("/proc/cpuinfo") as cpuinfo:
               for line in cpuinfo:
                   if line.startswith("flags"):
                       if "vmx" in line or "svm" in line:
                           has_virtualization = True
    return has_virtualization


def hardware_is_enabled():
    """Determins if virtualization hardware is available and enabled.

    Returns:
        True if there is hardware virtualization hardware available and enabled
    """
    is_enabled = False
    if hardware_is_available():
        has_module = False
        with open("/proc/modules") as modules:
            for line in modules:
                has_module = (line.startswith("kvm_intel") or
                              line.startswith("kvm_amd"))
                if has_module:
                    break
    if has_module and os.path.exists("/dev/kvm"):
        is_enabled = True
    return is_enabled


Version-Release number of selected component (if applicable):
ovirt-node-iso-2.6.0-20130212.fc18.iso


Steps to Reproduce:
1. Disable Intel/AMD virtuallization support in BIOS.
2. Install ovirt-node-iso and reboot.
3. Login ovirt-node and focus on Status page.

Actual results:
Shown wrong message "No virtualization hardware was detected on this system" in Status page when disable Intel/AMD virtuallization support in BIOS.

Expected results:
Shown correct message "Virtualization hardware was detected but is disabled" in Status page when disable Intel/AMD virtuallization support in BIOS.

Additional info:
----------

Comment 1 Fabian Deutsch 2013-03-11 10:47:00 UTC
This should fix it.
http://gerrit.ovirt.org/#/c/12920/

Comment 2 haiyang,dong 2013-05-23 09:49:47 UTC
Test version:
ovirt-node-iso-3.0.0-1.0.20130517.fc18.iso

Test steps:
1. Disable Intel/AMD virtuallization support in BIOS.
2. Install ovirt-node-iso and reboot.
3. Login ovirt-node and focus on Status page.

Shown correct message "Virtualization hardware was detected but is disabled" in Status page when disable Intel/AMD virtuallization support in BIOS.

so this bug has been fixed, change the status into "VERIFIED"

Comment 3 Sandro Bonazzola 2014-03-31 12:29:30 UTC
this is an automated message: moving to Closed CURRENT RELEASE since oVirt 3.4.0 has been released