Convert Vhd To Iso Image

11/7/2019
Convert Vhd To Iso Image Average ratng: 3,5/5 4633 votes
-->

Before you upload a Windows virtual machine (VM) from on-premises to Azure, you must prepare the virtual hard disk (VHD or VHDX). Azure supports both generation 1 and generation 2 VMs that are in VHD file format and that have a fixed-size disk. The maximum size allowed for the VHD is 1,023 GB.

Create Vhd From Iso

In a generation 1 VM, you can convert a VHDX file system to VHD. You can also convert a dynamically expanding disk to a fixed-size disk. But you can't change a VM's generation. For more information, see Should I create a generation 1 or 2 VM in Hyper-V? and Azure support for generation 2 VMs (preview).

For information about the support policy for Azure VMs, see Microsoft server software support for Azure VMs.

Note

Iso To Vhdx

Use Powershell to convert vhdx to wim. And let it do it’s thing. When you are done you can unmount the vhd and discard any changes using.

  1. You can use the pre-conversion method. Yes, this is the method in which we directly convert the ISO image file (.iso) into VDI (virtual disk image) format using VirtualBox. Not only to VDI but also using the same VBOXmanage tools of VirtualBox the user can convert the ISO image file to VDMK or VHD.
  2. Know how to convert VHD to VMware VMDK image by using WinImage, features of WinImage and steps to convert VHD to VMware VMDK format. Reading, and editing of many image formats and file systems such as Linux, FAT, ISO, NTFS DMF, and VHD. The disk image thus, created by using the tool that has actually exact copy of that physical disk.
  3. How to convert a windows WIM file to a ISO file I am trying to find a way to take a WIM file from WDS, and convert it to an ISO image, so that I can use the ISO to install into VMware machines. I've read the many posts on how to convert a discover.wim to an ISO, but this doesn't work for what I'm trying to do. Any suggestions on how to get.

The instructions in this article apply to:

  1. The 64-bit version of Windows Server 2008 R2 and later Windows Server operating systems. For information about running a 32-bit operating system in Azure, see Support for 32-bit operating systems in Azure VMs.
  2. If any Disaster Recovery tool will be used to migrate the workload, like Azure Site Recovery or Azure Migrate, this process is still required to be done and followed on the Guest OS to prepare the image prior the migration.

Convert the virtual disk to a fixed size and to VHD

If you need to convert your virtual disk to the required format for Azure, use one of the methods in this section:

  1. Back up the VM before you run the virtual disk conversion process.

  2. Make sure that the Windows VHD works correctly on the local server. Resolve any errors within the VM itself before you try to convert or upload it to Azure.

  3. Regarding the size of the VHD:

    1. All VHDs on Azure must have a virtual size aligned to 1MB. When converting from a raw disk to VHD you must ensure that the raw disk size is a multiple of 1 MB before conversion. Fractions of a megabyte will cause errors when creating images from the uploaded VHD.

    2. The maximum size allowed for the OS VHD is 2TB.

After you convert the disk, create a VM that uses the disk. Start and sign in to the VM to finish preparing it for uploading.

Use Hyper-V Manager to convert the disk

  1. Open Hyper-V Manager and select your local computer on the left. In the menu above the computer list, select Action > Edit Disk.
  2. On the Locate Virtual Hard Disk page, select your virtual disk.
  3. On the Choose Action page, select Convert > Next.
  4. If you need to convert from VHDX, select VHD > Next.
  5. If you need to convert from a dynamically expanding disk, select Fixed size > Next.
  6. Locate and select a path to save the new VHD file to.
  7. Select Finish.

Note

Use an elevated PowerShell session to run the commands in this article.

Use PowerShell to convert the disk

You can convert a virtual disk by using the Convert-VHD command in Windows PowerShell. Select Run as administrator when you start PowerShell.

The following example command converts the disk from VHDX to VHD. The command also converts the disk from a dynamically expanding disk to a fixed-size disk.

In this command, replace the value for -Path with the path to the virtual hard disk that you want to convert. Replace the value for -DestinationPath with the new path and name of the converted disk.

Convert from VMware VMDK disk format

If you have a Windows VM image in the VMDK file format, use the Microsoft Virtual Machine Converter to convert it to VHD format. For more information, see How to convert a VMware VMDK to Hyper-V VHD.

Set Windows configurations for Azure

On the VM that you plan to upload to Azure, run the following commands from an elevated command prompt window:

  1. Remove any static persistent route on the routing table:

    • To view the route table, run route print at the command prompt.
    • Check the Persistence Routes sections. If there's a persistent route, use the route delete command to remove it.
  2. Remove the WinHTTP proxy:

    If the VM needs to work with a specific proxy, add a proxy exception to the Azure IP address (168.63.129.16) so the VM can connect to Azure:

  3. Set the disk SAN policy to Onlineall:

    In the open command prompt window, type the following commands:

  4. Set Coordinated Universal Time (UTC) time for Windows. Also set the startup type of the Windows time service (w32time) to Automatic:

  5. Set the power profile to high performance:

  6. Make sure the environmental variables TEMP and TMP are set to their default values:

Check the Windows services

Make sure that each of the following Windows services is set to the Windows default values. These services are the minimum that must be set up to ensure VM connectivity. To reset the startup settings, run the following commands:

Update remote-desktop registry settings

Make sure the following settings are configured correctly for remote access:

Note

You might receive an error message when you run Set-ItemProperty -Path 'HKLM:SOFTWAREPoliciesMicrosoftWindows NTTerminal Services -Name <object name> -Value <value>. You can safely ignore this message. It means only that the domain isn't pushing that configuration through a Group Policy Object.

  1. Remote Desktop Protocol (RDP) is enabled:

  2. The RDP port is set up correctly. The default port is 3389:

    When you deploy a VM, the default rules are created against port 3389. If you want to change the port number, do that after the VM is deployed in Azure.

  3. The listener is listening in every network interface:

  4. Configure the network-level authentication (NLA) mode for the RDP connections:

  5. Set the keep-alive value:

  6. Reconnect:

  7. Limit the number of concurrent connections:

  8. Remove any self-signed certificates tied to the RDP listener:

    This code ensures that you can connect at the beginning when you deploy the VM. If you need to review this later, you can do so after the VM is deployed in Azure.

  9. If the VM will be part of a domain, check the following policies to make sure the former settings aren't reverted.

    GoalPolicyValue
    RDP is enabledComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesComponentsRemote Desktop ServicesRemote Desktop Session HostConnectionsAllow users to connect remotely by using Remote Desktop
    NLA group policySettingsAdministrative TemplatesComponentsRemote Desktop ServicesRemote Desktop Session HostSecurityRequire user authentication for remote access by using NLA
    Keep-alive settingsComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesWindows ComponentsRemote Desktop ServicesRemote Desktop Session HostConnectionsConfigure keep-alive connection interval
    Reconnect settingsComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesWindows ComponentsRemote Desktop ServicesRemote Desktop Session HostConnectionsReconnect automatically
    Limited number of connection settingsComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesWindows ComponentsRemote Desktop ServicesRemote Desktop Session HostConnectionsLimit number of connections

Configure Windows Firewall rules

  1. Turn on Windows Firewall on the three profiles (domain, standard, and public):

  2. Run the following command in PowerShell to allow WinRM through the three firewall profiles (domain, private, and public), and enable the PowerShell remote service:

  3. Enable the following firewall rules to allow the RDP traffic:

  4. Introduction to business law pdf. Enable the rule for file and printer sharing so the VM can respond to a ping command inside the virtual network:

  5. If the VM will be part of a domain, check the following Azure AD policies to make sure the former settings aren't reverted.

    GoalPolicyValue
    Enable the Windows Firewall profilesComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesNetworkNetwork ConnectionWindows FirewallDomain ProfileWindows FirewallProtect all network connections
    Enable RDPComputer ConfigurationPoliciesWindows SettingsAdministrative TemplatesNetworkNetwork ConnectionWindows FirewallDomain ProfileWindows FirewallAllow inbound Remote Desktop exceptions
    Computer ConfigurationPoliciesWindows SettingsAdministrative TemplatesNetworkNetwork ConnectionWindows FirewallStandard ProfileWindows FirewallAllow inbound Remote Desktop exceptions
    Enable ICMP-V4Computer ConfigurationPoliciesWindows SettingsAdministrative TemplatesNetworkNetwork ConnectionWindows FirewallDomain ProfileWindows FirewallAllow ICMP exceptions
    Computer ConfigurationPoliciesWindows SettingsAdministrative TemplatesNetworkNetwork ConnectionWindows FirewallStandard ProfileWindows FirewallAllow ICMP exceptions

Verify the VM

Make sure the VM is healthy, secure, and RDP accessible:

  1. To make sure the disk is healthy and consistent, check the disk at the next VM restart:

    Make sure the report shows a clean and healthy disk.

  2. Set the Boot Configuration Data (BCD) settings.

    Note

    Use an elevated PowerShell window to run these commands.

  3. The dump log can be helpful in troubleshooting Windows crash issues. Enable the dump log collection:

  4. Verify that the Windows Management Instrumentation (WMI) repository is consistent:

    If the repository is corrupted, see WMI: Repository corruption or not.

  5. Make sure no other application is using port 3389. This port is used for the RDP service in Azure. To see which ports are used on the VM, run netstat -anob:

  6. To upload a Windows VHD that's a domain controller:

    • Follow these extra steps to prepare the disk.

    • Make sure you know the Directory Services Restore Mode (DSRM) password in case you have to start the VM in DSRM at some point. For more information, see Set a DSRM password.

  7. Make sure you know the built-in administrator account and password. You might want to reset the current local administrator password and make sure you can use this account to sign in to Windows through the RDP connection. This access permission is controlled by the 'Allow log on through Remote Desktop Services' Group Policy Object. View this object in the Local Group Policy Editor here:

    Computer ConfigurationWindows SettingsSecurity SettingsLocal PoliciesUser Rights Assignment

  8. Check the following Azure AD policies to make sure you're not blocking your RDP access through RDP or from the network:

    • Computer ConfigurationWindows SettingsSecurity SettingsLocal PoliciesUser Rights AssignmentDeny access to this computer from the network

    • Computer ConfigurationWindows SettingsSecurity SettingsLocal PoliciesUser Rights AssignmentDeny log on through Remote Desktop Services

  9. Check the following Azure AD policy to make sure you're not removing any of the required access accounts:

    • Computer ConfigurationWindows SettingsSecurity SettingsLocal PoliciesUser Rights AssignmentAccess this computer from the network

    The policy should list the following groups:

    • Administrators

    • Backup Operators

    • Everyone

    • Users

      Streaming on Connected TVs (e.g. Smart TVs or streaming boxes) is restricted for Zattoo FREE accounts. As a PREMIUM customer, you get Zattoo HD at 50 frames per second. With Zattoo PREMIUM you can also watch two streams at once and there are no ads when changing channels. We're all set to go for the tournaments - now the Teams just have to deliver some goals. Zattoo FREE gives you a huge selection of TV channels, including:. Zattoo brings a huge selection of TV channels to you - for free. Watch your favorite TV channels such as ARD, ZDF, Sport1, DMAX, Comedy Central, Tele 5, CNN. Download zattoo live tv android, zattoo live tv android, zattoo live tv android download free. Zattoo tv free sender. Sep 12, 2016  Zattoo is a free application for Windows which allows you to watch TV channels directly in your computer Screen, with no cables or aerials. You only need an internet connection and your computer will be converted into a TV in a matter of seconds.

  10. Restart the VM to make sure that Windows is still healthy and can be reached through the RDP connection. At this point, you might want to create a VM in your local Hyper-V to make sure the VM starts completely. Then test to make sure you can reach the VM through RDP.

  11. Remove any extra Transport Driver Interface (TDI) filters. For example, remove software that analyzes TCP packets or extra firewalls. If you need to review this later, you can do so after the VM is deployed in Azure.

  12. Uninstall any other third-party software or driver that's related to physical components or any other virtualization technology.

Install Windows updates

Ideally, you should keep the machine updated at the patch level. If this isn't possible, make sure the following updates are installed:

Convert Vhd To Iso Image File

ComponentBinaryWindows 7 SP1, Windows Server 2008 R2 SP1Windows 8, Windows Server 2012Windows 8.1, Windows Server 2012 R2Windows 10 v1607, Windows Server 2016 v1607Windows 10 v1703Windows 10 v1709, Windows Server 2016 v1709Windows 10 v1803, Windows Server 2016 v1803
Storagedisk.sys6.1.7601.23403 - KB31255746.2.9200.17638 / 6.2.9200.21757 - KB31370616.3.9600.18203 - KB3137061----
storport.sys6.1.7601.23403 - KB31255746.2.9200.17188 / 6.2.9200.21306 - KB30184896.3.9600.18573 - KB402272610.0.14393.1358 - KB402271510.0.15063.332--
ntfs.sys6.1.7601.23403 - KB31255746.2.9200.17623 / 6.2.9200.21743 - KB31212556.3.9600.18654 - KB402272610.0.14393.1198 - KB402271510.0.15063.447--
Iologmsg.dll6.1.7601.23403 - KB31255746.2.9200.16384 - KB2995387-----
Classpnp.sys6.1.7601.23403 - KB31255746.2.9200.17061 / 6.2.9200.21180 - KB29953876.3.9600.18334 - KB317261410.0.14393.953 - KB4022715---
Volsnap.sys6.1.7601.23403 - KB31255746.2.9200.17047 / 6.2.9200.21165 - KB29753316.3.9600.18265 - KB3145384-10.0.15063.0--
partmgr.sys6.1.7601.23403 - KB31255746.2.9200.16681 - KB28771146.3.9600.17401 - KB300085010.0.14393.953 - KB402271510.0.15063.0--
volmgr.sys10.0.15063.0--
Volmgrx.sys6.1.7601.23403 - KB3125574---10.0.15063.0--
Msiscsi.sys6.1.7601.23403 - KB31255746.2.9200.21006 - KB29551636.3.9600.18624 - KB402272610.0.14393.1066 - KB402271510.0.15063.447--
Msdsm.sys6.1.7601.23403 - KB31255746.2.9200.21474 - KB30461016.3.9600.18592 - KB4022726----
Mpio.sys6.1.7601.23403 - KB31255746.2.9200.21190 - KB30461016.3.9600.18616 - KB402272610.0.14393.1198 - KB4022715---
vmstorfl.sys6.3.9600.18907 - KB40726506.3.9600.18080 - KB30631096.3.9600.18907 - KB407265010.0.14393.2007 - KB434541810.0.15063.850 - KB434541910.0.16299.371 - KB4345420-
Fveapi.dll6.1.7601.23311 - KB31255746.2.9200.20930 - KB29302446.3.9600.18294 - KB317261410.0.14393.576 - KB4022715---
Fveapibase.dll6.1.7601.23403 - KB31255746.2.9200.20930 - KB29302446.3.9600.17415 - KB317261410.0.14393.206 - KB4022715---
Networknetvsc.sys---10.0.14393.1198 - KB402271510.0.15063.250 - KB4020001--
mrxsmb10.sys6.1.7601.23816 - KB40227226.2.9200.22108 - KB40227246.3.9600.18603 - KB402272610.0.14393.479 - KB402271510.0.15063.483--
mrxsmb20.sys6.1.7601.23816 - KB40227226.2.9200.21548 - KB40227246.3.9600.18586 - KB402272610.0.14393.953 - KB402271510.0.15063.483--
mrxsmb.sys6.1.7601.23816 - KB40227226.2.9200.22074 - KB40227246.3.9600.18586 - KB402272610.0.14393.953 - KB402271510.0.15063.0--
tcpip.sys6.1.7601.23761 - KB40227226.2.9200.22070 - KB40227246.3.9600.18478 - KB402272610.0.14393.1358 - KB402271510.0.15063.447--
http.sys6.1.7601.23403 - KB31255746.2.9200.17285 - KB30425536.3.9600.18574 - KB402272610.0.14393.251 - KB402271510.0.15063.483--
vmswitch.sys6.1.7601.23727 - KB40227196.2.9200.22117 - KB40227246.3.9600.18654 - KB402272610.0.14393.1358 - KB402271510.0.15063.138--
Corentoskrnl.exe6.1.7601.23807 - KB40227196.2.9200.22170 - KB40227186.3.9600.18696 - KB402272610.0.14393.1358 - KB402271510.0.15063.483--
Remote Desktop Servicesrdpcorets.dll6.2.9200.21506 - KB40227196.2.9200.22104 - KB40227246.3.9600.18619 - KB402272610.0.14393.1198 - KB402271510.0.15063.0--
termsrv.dll6.1.7601.23403 - KB31255746.2.9200.17048 - KB29735016.3.9600.17415 - KB300085010.0.14393.0 - KB402271510.0.15063.0--
termdd.sys6.1.7601.23403 - KB3125574------
win32k.sys6.1.7601.23807 - KB40227196.2.9200.22168 - KB40227186.3.9600.18698 - KB402272610.0.14393.594 - KB4022715---
rdpdd.dll6.1.7601.23403 - KB3125574------
rdpwd.sys6.1.7601.23403 - KB3125574------
SecurityMS17-010KB4012212KB4012213KB4012213KB4012606KB4012606--
KB4012216KB4013198KB4013198--
KB4012215KB4012214KB4012216KB4013429KB4013429--
KB4012217KB4013429KB4013429--
CVE-2018-0886KB4103718KB4103730KB4103725KB4103723KB4103731KB4103727KB4103721
KB4103712KB4103726KB4103715

Note

To avoid an accidental reboot during VM provisioning, we recommend ensuring that all Windows Update installations are finished and that no updates are pending. One way to do this is to install all possible Windows updates and reboot once before you run the Sysprep command.

Determine when to use Sysprep

System Preparation Tool (Sysprep) is a process you can run to reset a Windows installation. Sysprep provides an 'out of the box' experience by removing all personal data and resetting several components.

You typically run Sysprep to create a template from which you can deploy several other VMs that have a specific configuration. The template is called a generalized image.

If you want to create only one VM from one disk, you don’t have to use Sysprep. Instead, you can create the VM from a specialized image. For information about how to create a VM from a specialized disk, see:

If you want to create a generalized image, you need to run Sysprep. For more information, see How to use Sysprep: An introduction.

Not every role or application that's installed on a Windows-based computer supports generalized images. So before you run this procedure, make sure Sysprep supports the role of the computer. For more information, see Sysprep support for server roles.

Generalize a VHD

Note

After you run sysprep.exe in the following steps, turn off the VM. Don't turn it back on until you create an image from it in Azure.

Iso Vs Vhd

  1. Sign in to the Windows VM.

  2. Run Command Prompt as an administrator.

  3. Change the directory to %windir%system32sysprep. Then run sysprep.exe.

  4. In the System Preparation Tool dialog box, select Enter System Out-of-Box Experience (OOBE), and make sure that the Generalize check box is selected.

  5. In Shutdown Options, select Shutdown.

  6. Select OK.

  7. When Sysprep finishes, shut down the VM. Don't use Restart to shut down the VM.

Now the VHD is ready to be uploaded. For more information about how to create a VM from a generalized disk, see Upload a generalized VHD and use it to create a new VM in Azure.

Convert Vhd To Iso Image Editor

Note

A custom unattend.xml file is not supported. Although we do support the additionalUnattendContent property, that provides only limited support for adding microsoft-windows-shell-setup options into the unattend.xml file that the Azure provisioning agent uses. You can use, for example, additionalUnattendContent to add FirstLogonCommands and LogonCommands. For more information, see additionalUnattendContent FirstLogonCommands example.

Complete the recommended configurations

Convert Vhd To Iso Image

The following settings don't affect VHD uploading. However, we strongly recommend that you configured them.

  • Install the Azure Virtual Machine Agent. Then you can enable VM extensions. The VM extensions implement most of the critical functionality that you might want to use with your VMs. You'll need the extensions, for example, to reset passwords or configure RDP. For more information, see Azure Virtual Machine Agent overview.

  • After you create the VM in Azure, we recommend that you put the page file on the temporal drive volume to improve performance. You can set up the file placement as follows:

    If a data disk is attached to the VM, the temporal drive volume's letter is typically D. This designation could be different, depending on your settings and the number of available drives.

    • We recommend disabling script blockers that might be provided by anti-virus software. They might interfer and block the Windows Provisioning Agent scripts executed when you deploy a new VM from your image.

Next steps