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

Bug 906774

Summary: [Admin Portal] Export of a template to export domain confuses number of VM's monitors
Product: Red Hat Enterprise Virtualization Manager Reporter: Jiri Belka <jbelka>
Component: ovirt-engineAssignee: Nobody's working on this, feel free to take it <nobody>
Status: CLOSED DUPLICATE QA Contact:
Severity: high Docs Contact:
Priority: unspecified    
Version: 3.2.0CC: acathrow, dyasny, iheim, lpeer, michal.skrivanek, Rhev-m-bugs, yeylon, ykaul
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: virt
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-03-06 12:17:18 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
engine.log, vdsm.log none

Description Jiri Belka 2013-02-01 13:03:30 UTC
Description of problem:

When I reimported previously exported template from export domain, inside template VM properties - console -> monitors - there is '0' in the list. Although previously there was '1'. This '0' normally doesn't appear in VM/template properties dialog.

Creating a new VM based on this template thus end in error:

  Error while executing action: VM exceeded the number of allowed monitors

During investigation I found out, it is already export of the template which makes it bogus.

This 'foobar2' template was never exported.

$ curl -sk -X GET -u 'admin@internal:xxxxxx' -H 'Accept: application/xml' https://10.34.63.76/api/templates | sed -n '/<name>foobar2/,/<monitors>/p'
        <name>foobar2</name>
        <link href="/api/templates/1fa7a87b-2134-426a-a071-3d47c6456e3e/disks" rel="disks"/>
        <link href="/api/templates/1fa7a87b-2134-426a-a071-3d47c6456e3e/nics" rel="nics"/>
        <link href="/api/templates/1fa7a87b-2134-426a-a071-3d47c6456e3e/cdroms" rel="cdroms"/>
        <link href="/api/templates/1fa7a87b-2134-426a-a071-3d47c6456e3e/permissions" rel="permissions"/>
        <type>desktop</type>
        <status>
            <state>ok</state>
        </status>
        <memory>536870912</memory>
        <cpu>
            <topology sockets="1" cores="1"/>
        </cpu>
        <os type="unassigned">
            <boot dev="hd"/>
            <kernel></kernel>
            <initrd></initrd>
            <cmdline></cmdline>
        </os>
        <cluster href="/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95" id="99408929-82cf-4dc7-a532-9d998063fa95"/>
        <creation_time>2013-02-01T13:57:02.904+01:00</creation_time>
        <origin>ovirt</origin>
        <high_availability>
            <enabled>false</enabled>
            <priority>1</priority>
        </high_availability>
        <display>
            <type>spice</type>
            <monitors>1</monitors>

Now what happens why I export it?

$ curl -sk -X GET -u 'admin@internal:xxxxxx' -H 'Accept: application/xml' https://10.34.63.76/api/storagedomains/131d564c-52d1-4bba-8d60-39e889a8bc08/templates | sed -n '/<name>foobar2/,/<monitors>/p'
        <name>foobar2</name>
        <description></description>
        <type>desktop</type>
        <status>
            <state>ok</state>
        </status>
        <memory>536870912</memory>
        <cpu>
            <topology sockets="1" cores="1"/>
        </cpu>
        <os type="unassigned">
            <boot dev="hd"/>
        </os>
        <storage_domain href="/api/storagedomains/131d564c-52d1-4bba-8d60-39e889a8bc08" id="131d564c-52d1-4bba-8d60-39e889a8bc08"/>
        <creation_time>2013-02-01T13:57:02.000+01:00</creation_time>
        <origin>ovirt</origin>
        <high_availability>
            <enabled>false</enabled>
            <priority>0</priority>
        </high_availability>
        <display>
            <type>spice</type>
            <monitors>0</monitors>

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

How reproducible:
100%

Steps to Reproduce:
1. create a vm (1 nic, 1 disk, check if number of monitors is '1')
2. export this vm to template
3. delete the template
4. reimport the template
5. check template properties (console -> monitors)
  
Actual results:
template is corrupted

Expected results:
number of monitors should be kept

Additional info:

Comment 1 Jiri Belka 2013-02-01 13:20:06 UTC
Created attachment 691579 [details]
engine.log, vdsm.log

Comment 2 Michal Skrivanek 2013-03-06 12:17:18 UTC

*** This bug has been marked as a duplicate of bug 917375 ***