Search

MachPanel Knowledgebase

GUIDE:SOP for preparation of Windows Sealed Images for Hyper-V (Hosted VPS)

Mudesira Munir
Configuration

Summary

This article provides information about preparation of sealed images for Windows Virtual Machines.

Applies To
Applies to MachPanel v5.3.10 and onward.
    Procedure for creating Windows VM Sealed Images

    STEP-1: CREATE VM

    Minimum Disk Space 10-12 GB: Create a VM to host the operating system of your choice with minimal disk space i.e. from 10 to 12 GB, as the purchased storage will then be added to respective VM later based on Service Plans.

    Other Settings:

    1. Adjust the Windows Firewall as per your requirements.
    2. Install antivirus & monitoring tools, if any.
    3. Allow Remote Desktop Connection.
    4. Set local Administrator Password to Never Expire.

    STEP-2: SEALED IMAGE NAME for GEN1 & GEN2:

    Sealed Image Name for Gen1 & Gen2: MachPanel creates and identifies Gen1 and Gen2 type Virtual Machines based on sealed image file name. Make sure the .vhdx file name contains R2 like "MachineName-R2.vhdx” to create Gen2 VM during provisioning.

    STEP-3 SCHEDULED TASK

    In order to set passwords of VM, we need to create a "Scheduled Task" in sealed image. Please review details below to create a scheduled task to allow MachPanel to "Set Password" and process other OS initialization steps in Gen1 & Gen2 VM: http://kb.machsol.com/Knowledgebase/Article/53471

    There is a difference between creation of scheduled task for Gen1 and Gen2 type virtual Machines as explained below:

    1. Scheduled Task for Gen1: For Gen1, you must add a "Floppy Disk" with VM of sealed image and Set Action to run “A:\Config.bat”.
    2. Scheduled Task for Gen2: For Gen2, you must add a "Scheduled Task" where Set Action to run “C:\Config.bat” because you can't create floppy for Gen2.

    STEP-4: PREPARE WINDOWS VM SEALED IMAGES

    Important: In windows startup, create a .bat file named as startup.bat and add A:\Config.bat as text in startup.bat file. (You can download the startup.bat directly from DOWNLOAD file section below found inside sysprep.zip file) 

    Install the desired operating system in VHD created in STEP-1. To sysprep the above windows installation do the following:

    1. Sample / Generic sysprep.xml file is provided. You can adjust it as per your requirements.
    2. Copy sysprep.xml to C:\Windows\System32\sysprep
    3. In Command Prompt type: C:\windows\system32\sysprep>sysprep /generalize /oobe /shutdown /unattend:sysprep.xml
    4. On completion, you will find the OS in shutdown state.
    5. ​Your sealed image is ready. Copy this VHD to some other safe place.
    6. You will need to specify the path to the folder that contains these VHDs in MachPanel configuration.

    Note: Please download sysprep.zip file from the DOWNLOAD File section. This zip file contains both startup.bat and sysprep.xml.

    Download
    Sysprep.zip
    1.00 KB, 873 views
    Details
    Type: GUIDE
    Access Type: Public
    Last Modified: Last Month
    Last Modified By: zohaib.shaikh
    Rated 3 stars based on 6 votes.
    Article has been viewed 19K times.
    Options
    Also In This Category
    Tags