Failover Cluster manager – get list of Vm’s and if a VM has a DVD (iso file)

Powershell Get-ClusterGroup -Cluster 19-hv | ? {$_.GroupType –eq ‘VirtualMachine’ } | Get-VM | Get-VMDvdDrive   19-hv is the cluster name I have created VMName ControllerType ControllerNumber ControllerLocation DvdMediaType Path —— ————– —————- —————— ———— —- 19-RDSH SCSI 0 1 None 2016DC-1 SCSI 0 1 None 2019 SCSI 0 1 None Android IDE 1 0 ISO […]

Posted in KB - Server, KB - Windows Server, KB-HyperV, KB-Powershell/CMD, KB-Software, KB-Windows, Knowledge Base | Comments Off on Failover Cluster manager – get list of Vm’s and if a VM has a DVD (iso file)

Hyper-V get VM VHD Used and Provisioned Storage

Open Powershell as admin   Get-VM | ForEach { $Vm = $_; $_.HardDrives } | ForEach { $GetVhd = Get-VHD -Path $_.Path [pscustomobject]@{ Vm = $Vm.Name Name = $_.Name Type = $GetVhd.VhdType ProvisionedGB = ($GetVhd.Size / 1GB) CommittedGB = ($GetVhd.FileSize / 1GB) } } | Export-Csv -Delimiter “;” -Path “C:\temp\VMVHDStorageUsedTotal.csv”   Creates CSV with data […]

Posted in KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on Hyper-V get VM VHD Used and Provisioned Storage

Hyper-V get VM VHD locations

Run Powershell as admin   get-vm * | select Name,@{L=”Disks”;E={$_.harddrives.path}} | Export-Csv c:\temp\vmdisklocations.csv     Creates CSV which looks like the below Name Disks WACLS1-VM S:\VM\WACLS1-vm.vhdx H:\VMs HDD\WACLS1-VM\WACLS1-backupdisk.vhdx H:\VMs HDD\WACLS1-VM\WACLS!-VMM-Lib.vhdx

Posted in KB - Server, KB - Windows Server, KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on Hyper-V get VM VHD locations

hyper-v Enable processor compatibility

Enabling this feature manually on each vm, via settings processor > expand > Compatibility > tick Migrate to a physical computer with a different processor version   View current status of all vm’s on a host. PS C:\WINDOWS\system32> Get-VM | get-VMProcessor VMName Count CompatibilityForMigrationEnabled CompatibilityForOlderOperatingSystemsEnabled —— —– ——————————– ——————————————– Activation-Test 1 False False AzureADConnect2 1 […]

Posted in KB - Server, KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on hyper-v Enable processor compatibility

Ubuntu 16.04 Gen 2 VM keyboard not recognised

Ubuntu 16.04 Gen 2 VM keyboard not recognised Cause: secure boot breaking keyboard under the serer installer workaround disable secure boot on VM

Posted in KB - Server, KB-HyperV, Knowledge Base | Comments Off on Ubuntu 16.04 Gen 2 VM keyboard not recognised

VM kept a recovery checkpoint

Not sure why this occurred however I was planning to add a new drive to a vm, however could not add the new drive. Thinking back to an issue with a VM at work, on my VM exchange I tried to edit an existing drive on the VM and it mentions checkpoints exist. In poweshell […]

Posted in KB - Windows Server, KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on VM kept a recovery checkpoint

Export list of Mac addresses used by Hyper-V VMs

Run Powershell as admin Get-vm | Get-VMNetworkAdapter | select-object VMname, Macaddress, Name | Export-Csv -Delimiter “;” -Path C:\vmmacs.csv VMName = name of the virtual machine Macaddress = Mac of the VM being used Name = The type of network adapter being used such as Network Adapter and Legacy Network Adapter Delimiter is ; which is […]

Posted in KB - Windows Server, KB-HyperV, Knowledge Base | Comments Off on Export list of Mac addresses used by Hyper-V VMs

Hide Hyper V Floppy Disk Drive via group policy

On Any Hyper-V virtual machine it adds the Floppy disk drive, and there is not an option to remove the drive from the settings window of the VM   The Way to remove this drive is by changing a value in the registry of the virtual machine that is running windows. However as I join […]

Posted in KB - Windows Server, KB- Group Policy, KB-HyperV, Knowledge Base | Comments Off on Hide Hyper V Floppy Disk Drive via group policy

Hyper-V Guest Operating Systems that support Dynamic Memory

Linux distributions For details on Linux distributions and versions that support dynamic memory, and the requirements for Linux Integration Services, see Linux and FreeBSD Virtual Machines on Hyper-V. Windows Server 2012 and Windows Server 2012 R2 Datacenter, Standard, and Essentials editions. Integration services are built-in and do not require a separate download and installation. Windows 8 […]

Posted in KB - Windows Server, KB-HyperV, Knowledge Base | Comments Off on Hyper-V Guest Operating Systems that support Dynamic Memory

Enabling Nested Virtualization

A Hyper-V host running Windows Server 2016 or Windows 10 Anniversary Update. A Hyper-V VM running Windows Server 2016 or Windows 10 Anniversary Update. A Hyper-V VM with configuration version 8.0 or greater. An Intel processor with VT-x and EPT technology. Shutdown VM Open Powershell as admin and run this command on Hyper-V host “Set-VMProcessor […]

Posted in KB - Windows Server, KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on Enabling Nested Virtualization