Bug 1419562 - [Sysprep] windows 2012 R2 and windows 2016 - failed to load sysprep file
Summary: [Sysprep] windows 2012 R2 and windows 2016 - failed to load sysprep file
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Virt
Version: 4.1.0.3
Hardware: Unspecified
OS: Windows
urgent
urgent
Target Milestone: ovirt-4.1.1
: 4.1.1.3
Assignee: Tomas Jelinek
QA Contact: Israel Pinto
URL:
Whiteboard:
Depends On:
Blocks: 1388724
TreeView+ depends on / blocked
 
Reported: 2017-02-06 13:58 UTC by Israel Pinto
Modified: 2017-04-21 09:47 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
A problem with Windows server operating system sysprep provisioning failing when the RHV configuration does not provide a valid Product Key was fixed. Using an empty key caused the provisioning to stop without completing other items, so the configuration section in Unattend.xml is now automatically removed. Custom sysprep script is not affected as it is entirely provided by users. The expectation is that it does contain a valid key and a potential Product Key section is intentional.
Clone Of:
Environment:
Last Closed: 2017-04-21 09:47:42 UTC
oVirt Team: Virt
Embargoed:
rule-engine: ovirt-4.1+
rule-engine: blocker+
rule-engine: planning_ack+
michal.skrivanek: devel_ack+
mavital: testing_ack+


Attachments (Terms of Use)
screenshot win 2012 (110.62 KB, image/png)
2017-02-06 13:58 UTC, Israel Pinto
no flags Details
engine.log (706.85 KB, application/zip)
2017-02-06 14:12 UTC, Israel Pinto
no flags Details
vdsm log (298.07 KB, application/zip)
2017-02-06 14:15 UTC, Israel Pinto
no flags Details
windows_2012_details (163.21 KB, image/png)
2017-02-06 15:59 UTC, Israel Pinto
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 72426 0 master MERGED core: remove the ProductKey section if product key is not provided 2020-04-27 09:24:23 UTC
oVirt gerrit 72489 0 ovirt-engine-4.1 MERGED core: remove the ProductKey section if product key is not provided 2020-04-27 09:24:23 UTC

Description Israel Pinto 2017-02-06 13:58:16 UTC
Created attachment 1248042 [details]
screenshot win 2012

Description of problem:
Setting sysprep with windows 2012 R2 64B 
Failed to load answer file.

Version-Release number of selected component (if applicable):
Red Hat Virtualization Manager Version: 4.1.0.3-0.1.el7


How reproducible:
all the time

Steps to Reproduce:
1. Create win 2012 R2 64B VM 
2. Seal VM and create template
3. Create from template VM and set sysprep:
Setting: 
1. VM Hostname
2. Time Zone
3. Admin password
4. Custom Local:
   Input Locale: en-GB
   UI Language:  en-GB
   

Actual results:
Failed in starting VM 
Error windows:
"Windows could not parse or process the unattend answer file for pass [specialize]. The settings specified in the answer file cannot be applied. The error was detected while processing settings for component [Microsoft-Windows-Shell-Setup]."

Unattend.xml:                
<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
    <settings pass="specialize">
        <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <ComputerName><![CDATA[win2012_sysprep]]></ComputerName>
            <RegisteredOrganization><![CDATA[scl.lab.tlv.redhat.com]]></RegisteredOrganization>
            <RegisteredOwner>User</RegisteredOwner>
            <ProductKey><![CDATA[]]></ProductKey>
        </component>
        <component name="Microsoft-Windows-UnattendedJoin" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <Identification>
                <Credentials>
                    <Domain><![CDATA[]]></Domain>
                    <Password><![CDATA[]]></Password>
                    <Username><![CDATA[]]></Username>
                </Credentials>
                <DebugJoin>true</DebugJoin>
                <JoinDomain><![CDATA[]]></JoinDomain>
                <MachineObjectOU><![CDATA[]]></MachineObjectOU>
            </Identification>
        </component>
    </settings>
    <settings pass="oobeSystem">
        <component name="Microsoft-Windows-IE-ClientNetworkProtocolImplementation" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <HKLMProxyEnable>false</HKLMProxyEnable>
        </component>
        <component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <InputLocale><![CDATA[ en-GB]]></InputLocale>
            <SystemLocale><![CDATA[en_US]]></SystemLocale>
            <UILanguage><![CDATA[ en-GB]]></UILanguage>
            <UILanguageFallback>en-US</UILanguageFallback>
            <UserLocale><![CDATA[en_US]]></UserLocale>
        </component>
        <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <Display>
                <ColorDepth>32</ColorDepth>
                <HorizontalResolution>1024</HorizontalResolution>
                <RefreshRate>75</RefreshRate>
                <VerticalResolution>768</VerticalResolution>
            </Display>
            <OOBE>
                <HideEULAPage>true</HideEULAPage>
                <SkipUserOOBE>true</SkipUserOOBE>
            </OOBE>
            <UserAccounts>
                <AdministratorPassword>
                    <Value><![CDATA[test]]></Value>
                    <PlainText>true</PlainText>
                </AdministratorPassword>
            </UserAccounts>
            <RegisteredOrganization><![CDATA[scl.lab.tlv.redhat.com]]></RegisteredOrganization>
            <RegisteredOwner>User</RegisteredOwner>
            <TimeZone><![CDATA[Tonga Standard Time]]></TimeZone>
        </component>
    </settings>
    <settings pass="windowsPE">
        <component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <SetupUILanguage>
                <UILanguage><![CDATA[ en-GB]]></UILanguage>
            </SetupUILanguage>
            <InputLocale><![CDATA[ en-GB]]></InputLocale>
            <UILanguage><![CDATA[ en-GB]]></UILanguage>
            <SystemLocale><![CDATA[en_US]]></SystemLocale>
            <UILanguageFallback>en-US</UILanguageFallback>
            <UserLocale><![CDATA[en_US]]></UserLocale>
        </component>
        <component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <UserData>
                <ProductKey>
                    <Key><![CDATA[]]></Key>
                    <WillShowUI>Never</WillShowUI>
                </ProductKey>
                <AcceptEula>true</AcceptEula>
                <Organization><![CDATA[scl.lab.tlv.redhat.com]]></Organization>
                <FullName>User</FullName>
            </UserData>
        </component>
    </settings>
    <cpi:offlineImage cpi:source="catalog://catalogs/windows2012-x86/sources/install_windows longhorn serverenterprise.clg" xmlns:cpi="urn:schemas-microsoft-com:cpi" />
</unattend>

Comment 1 Israel Pinto 2017-02-06 14:12:21 UTC
Created attachment 1248043 [details]
engine.log

Comment 2 Israel Pinto 2017-02-06 14:15:43 UTC
Created attachment 1248044 [details]
vdsm log

Comment 3 Michal Skrivanek 2017-02-06 15:54:29 UTC
please share the exact windows version/image used for this test

Comment 4 Israel Pinto 2017-02-06 15:59:24 UTC
Created attachment 1248071 [details]
windows_2012_details

Comment 5 Israel Pinto 2017-02-06 16:00:06 UTC
(In reply to Michal Skrivanek from comment #3)
> please share the exact windows version/image used for this test

see attached windows_2012_details

Comment 6 Tomáš Golembiovský 2017-02-06 20:37:02 UTC
The problem is a Product Key is missing.

Comment 8 Israel Pinto 2017-02-08 16:42:52 UTC
Recheck it with Product Key  in sysprep answering file
and got the same error.

Comment 13 Israel Pinto 2017-03-06 14:54:51 UTC
Verify with:
Engine: 4.1.1.3-0.1.el7
Host:
OS Version:RHEL - 7.3 - 7.el7
Kernel Version:3.10.0 - 550.el7.x86_64
KVM Version:2.6.0 - 28.el7_3.3.1
LIBVIRT Version:libvirt-2.0.0-10.el7_3.5
VDSM Version:vdsm-4.19.7-1.el7ev

Steps:
With windows 2012 R2 64B and windows 2016 R2 64B
1. Create VM with sysprep setting, run vm and check VM 
2. Create VM with sysprep file without password run vm and check VM  
3. Create VM with sysprep file with password run vm and check VM  
Results:

All cases pass


Note You need to log in before you can comment on or make changes to this bug.