Quantcast
Channel: Hyper-V forum
Viewing all 19461 articles
Browse latest View live

How to enable HPET on a Hyper-V VM

$
0
0

I have been searching for documentation on how to properly enable the HPET on a Hyper-V. I haven't been able to find anything specifying if it works or not, and if it does work, how to properly enable it. From our initial tests, it doesn't seem to be consistent with either the machines timer or the HPET.

We are deploying Lync and UCMA based applications and have noticed a significant performance difference between machines with HPET enable and HPET disabled in terms of their ability to handle capacity. We would like to be able to virtualize these machines, but the HPET is currently our limiting factor.

Can anyone point me in the right direction to find an answer?


Error on live migration

$
0
0

Hello,

I have been doing a live migrations with several machines and I am having an issue with only one of the VM's. It will not do a live migration and gives me the following error.

Error (12700)
VMM cannot complete the host operation on the (ServerName) server because of the error: Storage migration for virtual machine 'SERVER' (2C4C28E1-791A-4474-A74C-1D4E7436D134) failed with error 'Data error (cyclic redundancy check).' (0x80070017).

Migration did not succeed. Mirror operation failed for the source VHD file 'I:\SERVER\SERVER.vhdx' to the destination file 'D:\IMAGES\SERVER\SERVER.vhdx': 'Data error (cyclic redundancy check).'('0x80070017').
Unknown error (0x8000)

Recommended Action
Resolve the host issue and then try the operation again.

Anyone have any suggestions? the server is running fine and there are no other errors that can lead me to the problem?

Thanks,

Gavin...

You cannot migrate a Hyper-V virtual machine from a non-Bulldozer-based computer to a Bulldozer-based computer in Windows Server 2008 R2

$
0
0

Title is taken from an available hotfix KB2752183 http://support.microsoft.com/kb/2752183

Symptoms state:

  • The source node is located on a computer that has an AMD processor that was released earlier than the Bulldozer family of processors. For example, the computer has an AMD Opteron 6100 series processor.
  • The destination node is located on a computer that has an AMD Bulldozer processor. For example, the computer has an AMD Opteron 6200 series processor.

In this scenario, the migration fails, and you receive a message that states that the destination node is incompatible.

I have this exact scenario on my production cluster.
Was 2 nodes with AMD 6134(Pre-Bulldozer) and have now added another node with an AMD 6234 (Bulldozer).

My question is how to install the hotfix? As the KB article doesn't state where to install it.

Would it need installing only on the Pre-Bulldozer servers?
Or the Bulldozer server?
Or all three?

Hyper-V Manager Stops

$
0
0

I am running Windows 2012 with Hyper-V installed.  Currently have 1 VM running.  I spend most of my time on the VM, but when I have to restart it, it does not come back up.  Logging into the Windows 2012 server and open Hyper-V Manager, the VM is not there and under Actions, says to Start Service.

This has been a continual problem with no errors in the event log.  There is no SCCM installed as I have read in other posts.

Unique identification of a VM through VM GUID from inside the guest.

$
0
0

Hello, We use an internally built inventory and asset management solution.

We are facing the following issue : How to identify uniquely a computer,  knowing that it can be a VM and that a VM may have been duplicated ?

Let me clarify : a VM that is imported in Hyper-V, may have ALL the usual IDs you can access from the guest identical to another VM :

That is : same UUID, same MAC address, same SID, same BIOS ID, same Netbios name. Of course, the won't be able to function well in the same domain/forest unless properly isolated and this usually is not something you want to have in a production environment.

But let's face it, it may happen and if it is all you have as a primary key used to differentiate machines in a relational database, then you're screwed.

So i thought that the best way would be to access the VM GUID (the one of the XML VM files) and add it to build the primary key.

It is no problem using WMI and Msvm_KvpExchangeComponent from the host, but it would be nice to have access to this data through the guest, meaning that the KVP should be exposed on the guest too through the integration components.

Feel free to discuss, i think it is an important issue.

The serve encountered an error while creating XXX. The operation failed. (Event ID 13000, error code 0x80070522)

$
0
0
  • OS: Windows Server 2008 R2 with Hyper-V role installed
  • Logon user account: Default Domain Adminstrator and RDPed to this Hyper-V host server directly (not using RSAT remotely)

There were no issues in the past.

The description for Event ID 13000 from source Microsoft-Windows-Hyper-V-VMMS cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.

If the event originated on another computer, the display information had to be saved with the event.

The following information was included with the event:

%%2147943714
0x80070522
MyDomain\Administrator
E:\Test Virtual Machines\Windows Server 2008 R2 Standard Template

The locale specific resource for the desired message is not present


Hyper-V Svr R2 install problem; unable to create a new system partition or locate an existing system partition

$
0
0
I`m trying to install Hyper-V Server R2 (not 2008 server with the Hyper-V role, just Hyper-V) on a PowerEdge R610 with 2 15k SAS drives in a RAID1 config.  Booting to the Hyper-V DVD, when install gets to the "Where do you Want to Install Windows?" screen, I select my 67.5 gb logical drive (no partitions created at this point) and the installer says "Unable to create a new system partition or locate an existing system partition.  See the Setup logfiles for more information."  I`ve tried deleting my logical disk on the controller and recreating, deleting and recreating the partitions within the windows setup wizard, and setting up a non-RAID config (just 2 66GB disks) with the same result.  Has anyone seen this before or have any ideas?  Also, I have tried using diskpart from the recovery console to clean all attributes, rewrite a disk signature, delete and recreate partitions, format a new partition, with the same result.

C# code to remove or Eject the floppy drive

$
0
0

Hi guyz, i got the below code from MSDN regarding removal of resources from vm. The below example is for removing some nic settings.

What i need is to remove or Eject the Floppy disk which i have earlier attached from a virtual machine.

I followed the below procedure, but every time it gives me "Failed to remove resources from virtual machine"

Can any plz give working c# code to eject floppy drive(not through Powershell)

using System;
using System.Management;

namespace HyperVSamples
{
    class RemoveVirtualSystemResourcesClass
    {
        ManagementObject virtualSystemService = null;
        ManagementScope scope = null;

        RemoveVirtualSystemResourcesClass()
        {
            scope = new ManagementScope(@"root\virtualization", null);
            virtualSystemService = Utility.GetServiceObject(scope, "Msvm_VirtualSystemManagementService");
        }

        ManagementObject GetVirtualSystemEthernetPortSetting(ManagementObject vmSetting, string SyntheticNicElementName)
        {
            ManagementObject SyntheticNicSetting = null;
            ManagementObjectCollection SyntheticNicSettings = vmSetting.GetRelated
            (
             "Msvm_SyntheticEthernetPortSettingData","Msvm_VirtualSystemSettingDataComponent",
                null,
                null,"PartComponent","GroupComponent",
                false,
                null
            );

            foreach (ManagementObject instance in SyntheticNicSettings)
            {
                if (instance["ElementName"].ToString().ToLower() == SyntheticNicElementName.ToLower())
                {
                    SyntheticNicSetting = instance;
                    break;
                }
            }

            return SyntheticNicSetting;

        }

        void RemoveVirtualSystemResources(string vmName, string syntheticNicName)
        {

            ManagementObject vm = Utility.GetTargetComputer(vmName, scope);
            ManagementObject vmSetting = Utility.GetVirtualSystemSettingData(vm);

            ManagementObject syntheticNicPortSetting = GetVirtualSystemEthernetPortSetting(vmSetting, syntheticNicName);

            ManagementBaseObject inParams = virtualSystemService.GetMethodParameters("RemoveVirtualSystemResources");
            inParams["TargetSystem"] = vm.Path.Path;
            string[] resources = new string[1];
            resources[0] = syntheticNicPortSetting.Path.Path;

            inParams["ResourcesettingData"] = resources;

            ManagementBaseObject outParams = virtualSystemService.InvokeMethod("RemoveVirtualSystemResources", inParams, null);

            if ((UInt32)outParams["ReturnValue"] == ReturnCode.Started)
            {
                if (Utility.JobCompleted(outParams, scope))
                {
                    Console.WriteLine("SyntheticNic was removed successfully.");

                }
                else
                {
                    Console.WriteLine("Failed to remove SyntheticNic from VM");
                }
            }
            else if ((UInt32)outParams["ReturnValue"] == ReturnCode.Completed)
            {
                Console.WriteLine("SyntheticNic was removed successfully.");
            }
            else
            {
                Console.WriteLine("Remove SyntheticNic failed with error : {0}", outParams["ReturnValue"]);
            }

            inParams.Dispose();
            outParams.Dispose();
            vm.Dispose();
            vmSetting.Dispose();
            syntheticNicPortSetting.Dispose();
        }

        void Close()
        {
            this.virtualSystemService.Dispose();
        }

        static void Main(string[] args)
        {
            if (args != null && args.Length != 2)
            {
                Console.WriteLine("Usage: RemoveVirtualSystemResources vmName syntheticNicName");
                Console.WriteLine("Example: RemoveVirtualSystemResources MyFirstVM myStaticNic");
                return;
            }

            RemoveVirtualSystemResourcesClass removeResource = new RemoveVirtualSystemResourcesClass();
            removeResource.RemoveVirtualSystemResources(args[0], args[1]);
            removeResource.Close();
        }
    }
}

Similar to the above example, i have used the getfloppy setting instead of nic setting, but here it always gives me, count =0 in "cSettings" object, so the foreach loop doesn't even iterates once. I have simple replaced "Msvm_SyntheticEthernetPortSettingData" with "Msvm_DisketteDrive"... i know that im definitely doing something wrong here... can any one please help me here

 public static ManagementObject GetFloppySetting(ManagementObject vmSetting, string floppyElementName)
        {
            ManagementObject floppySetting = null;
            ManagementObjectCollection cSettings = vmSetting.GetRelated
            ("Msvm_DisketteDrive","Msvm_VirtualSystemSettingDataComponent",
                null,
                null,"PartComponent","GroupComponent",
                false,
                null
            );

            foreach (ManagementObject instance in SyntheticNicSettings)
            {
                if (instance["ElementName"].ToString().ToLower() == floppyElementName.ToLower())
                {
                    floppySetting = instance;
                    break;
                }
            }

            return floppySetting;

        }




Roles to install on a host to manage it from the Internet

$
0
0

Hello,

I'm planning the installation of a Windows Server 2012, and I need to manage the Hyper-V host from anywhere via the Internet.

My main question is : do I need to install the Remote Desktop Services role on the host (and which components) ?  If not, does it imply that the host can be reached from the Internet (using correct routing and firewall rules) via port 3389 ?

A more generic question : on a Hyper-V host, which roles (other than Hyper-V) must be installed ?

Thanks in advance for your help.



Windows Server 2012 - Can occasionally not access second virtual hard drive inside a VM

$
0
0

I run Windows Server 2012 RTM Hyper-V and I can occasionally not access the second virtual hard drive (dynamically expanding VHDX) attached to the VM through the virtual SCSI controller. I can however access the first hard drive that is connected with the virtual IDE controller.

I get the following warning in the event log under “Administrative Events” every 30 seconds when this happens:

  • Log Name: System
  • Source: Storvsc
  • ID: Storvsc
  • Message: “Reset to device, \Device\RaidPort0, was issued.”

I get this error once or twice a week and it has caused serious problems since one of the virtual servers that have this problem is a fileserver and the second hard drive contains all the data.

The only quick solution to the problem that I have found is to force the virtual machine to stop using the “Turn Off” feature since a normal shut down does not work (stops at shutting down the event log or similar) and then start the virtual machine again.

You can also wait for about 30 minutes or longer until the disk for some reason becomes accessible again by itself.

My research into this problem shows that:

  • Only 2 of the 10 VMs running Windows Server 2012 RTM that I have, have this problem.
  • Both these VMs have a second virtual hard drive (dynamically expanding VHDX) that cannot be accessed for 30 minutes or longer.
  • Check Disk of the virtual hard drive shows no errors.
  • The second hard drive is attached to the virtual SCSI controller.
  • I can find no problems at all with the physical storage on the (not related) 4 hosts that I have. The problem exists only in the VMs.

I have now attached the second virtual hard drive to the virtual IDE controller to see if this permanently fixes this problem (i.e. does not happen for at least a week).

Is there something wrong with the virtual SCSI controller or the virtual SCSI device driver that comes with Windows Server 2012 RTM? Does anyone else have this problem?

How do I shrink a VHD prior to converting to a VHDX

$
0
0

I'm doing a test run through of converting all of the servers to Server 2012 Hyper-V but I have one server that is giving me fits.  It's Windows 2008R2 with a huge "D" drive.  No one wants me to touch the current production server so reducing the size of the partition isn't an option.  My objective is to get the actual disk utilized by the fixed VHDX files to be reasonable.

My process (same for all of the servers):

1)  run disk2vhd with the Virtual PC option enabled to a USB drive and then copy this to the 2012 server - let's call it TEMP.VHD

2)  create a new VM and attach TEMP.VHD and the VM name is TEMP

3)  start TEMP, use disk management, shrink to 500GB, shutdown, delete the TEMP VM

4)  run VHDresizer from TEMP to a new name TEMP_SMALLER and shrink from 858GB to 350GB {this takes a long time but runs fine}

5)  in Hyper-V convert TEMP_SMALLER to a VHDX named DEV-XX {it's a software development house so all the VHDX files are fixed size}

6)  create a new VM and attach DEV-XX

7)  get a BSOD with 0x0000007B

So what's a better procedure / where did I error / etc.?

Wireless LAN Service feature not available in Hyper-V standalone server

$
0
0

Hi!

I'm trying to evaluate Hyper-V standalone server on a box with only a usb wireless network adapter for network connectivity. It's command line only, so I ran into some problems right from the start.

I was able to install the driver using

pnputil -i -a myManufacturersDriver.inf

This didn't magically provice networking capabilities. I figures out that I probably need the Server feature "wireless networking" but when I try to install this, it doesn't seem to be available! Am I skipping a step? Can I point to another package source? Can I download this feature somewhere from microsoft.com?

Please help me, I'm eager to investigate Win 2012 Hyper-V Standalone Server.

Kind regards,
Gerard Veneman.

How to enum / query a NIC / port for VLAN ID?

$
0
0

Hi,

I have been spending some time now searching for an example on how to query a Windows machine remotely for which VLAN ID's is present in a trunk configuration? So more or less, I create a Hyper-V server, create a virtual switch which has multiple VLAN's in it in a trunked configuration, and then I want to be able to remotely query the Hyper-V server (not VM or from within the Hyper-V cmdlets) for which VLAN ID's that are present in the trunk (not the VLAN's that I have set for the VM)! Even though Windows is not VLAN aware in itself, I guess this must be possible as network sniffers (wireshark / netmon) can display that stuff for me... so more or less, any example leading me in the right way would be appreciated - that being C#, PowerShell, C, C++, forum link, articles, blog or whatever.....

Thanks....


br4tt3

Virtual Switch (external) and Routing

$
0
0

I'm new to Hyper-V, so it will be difficult for me to describe the problem. But i'll try to :)

There's Server 2012 with 2 NICs: one looking to lan, another is connected to ADSL modem. RRAS is already configured on the server, with Remote Router interface (on-demand PPPoE connection). Everything works fine: lan clients have access to internet through the server. Now we are installing Hyper-V. To give access from VMs to lan and Internet we have to add External Virtual Switch over the NIC, which looks into lan, yes? But in that case client computers from local network do not have access to Internet.

Any ideas?

Migrate from VMware to Hyper-V 2012 with single SAN

$
0
0
Hi We currently have a 2 node VMware cluster connected to an iSCSI SAN running esx 4.1. Our VMware maintenance runs out in just under a years time and we would like to plan a migration from VMware to hyper-v. All of our infrastructure sits on the SAN. (We do have replicated dr and backup but that's not important) What we want to do is migrate all guests from VMware to hyper-v with as little down time and risk as possible. We also have a 3 node hyper-v node connected to a much smaller iSCSI SAN which we have been using for testing. We have been exploring ways to get all our servers migrated, but the sticking point is the storage. We can host 5 of our 20 servers on the hyper-v storage but then we would run out of space. Is it feasible to migrate these 5 servers, then delete the LUNs from the VMware storage, recreate and attach to hyper-v and use to store more of the migrated devices? Is this a sensible approach, or is there a much simpler way that we've missed. For info, we are a high school, and don't have the finance to purchase more storage. We do have an education version of System Centre if this would make the process any simpler. We also run Veeam essentials for replication and backup, but its only currently licences for the VMware hosts. Any help/advice/pointers would be appreciated.

Adding SCSI drives to an Openfiler guest on Hyper-v core

$
0
0

Hello

I am new to Hyper-V and maybe this question has been answered in another thread but I can't find it. I have installed an VM guest machine running Openfiler 2.99.1 on Hyper-v Core. It boots up fine and i am able to access. My problem is that I added SCSI Controllers then added additional Virtual SCSI drives to the Openfiler Guest Machine. After starting the machine i am unable to see the new SCSI disks. Can some tell me what I am doing wrong and how to fix it? I am using vtUtilities to manage my Hyper-V machines.

Thanks.

Hyper-v 3.0 Virtual SANs/FC with Failover Cluster

$
0
0

I have been trying to use Virtual SANs/FC Adapters in my 2012 Hyper-v failover clusters. I have run into a couple problems which have led me to remove failover clustering and go with stand-alone hosts, which seems more stable. If anyone has experienced similar issues and has better fixes, that would be fantastic.   

SAN Details:
- HP EVA4000
- OpenIndiana ZFS storage server
- HP Brocade 4 and 8 Gb FC switches

Host details:
- HP BL465c G7 blade servers
- HP LPe1105 HBAs
- Latest HP MPIO DSM for EVA, Microsoft DSM for OI LUNs
- Latest HP SPP (firmware and drivers)

Issues:

  1. If a node is reset or crashes, a VM using virtual FC adapters will not start on any nodes in the cluster--I receive "an unknown NPIV error occurred”. In order to start the VM, I have to swap the WWPNs on the A and B ports on each virtual FC adapter. The VM will not Live Migrate (since I can't use the second WWPN) until all nodes in the cluster have been rebooted.
  2. After removing a node from the failover cluster, the previously working vSANs stop working. If I remove the vSANs, I cannot add them back because Hyper-v decides that the HBA driver no longer supports NPIV. The only fix I have found is a rebuild...which is hardly a fix. Haven't been able to get deep enough into HP's support to find someone who knows what "NPIV" means
  3. This seems like it may be on my storage side, but a couple time my clusters started failing roles back and forth until they locked up and had to be totally rebooted to restore them. 

Matthew

Two Hyper-v servers connected to one iomega nas using iscsi creating folders on one server not reflecting on the other

$
0
0

We are using two Windows 2012 Hyper-v servers gui on iscsi. We have two servers connecting to the iscsi device it's a iomega ix4-200d nas. We have noticed that if on one server you make directory name change or a file name change it doesn't reflect that change on the other server... How can we fix this?

Thanks,

Mike

Downloading SCVVM 2012 SP1 for Hyperv

$
0
0

Can anyone share the link to download scvvm 2012 SP1. Also any documents on its installation would be helpful.

Thanks in advance

C# code to remove or Eject the floppy drive

$
0
0

Hi guyz, i got the below code from MSDN regarding removal of resources from vm. The below example is for removing some nic settings.

What i need is to remove or Eject the Floppy disk which i have earlier attached from a virtual machine.

I followed the below procedure, but every time it gives me "Failed to remove resources from virtual machine"

Can any plz give working c# code to eject floppy drive(not through Powershell)

using System;
using System.Management;

namespace HyperVSamples
{
    class RemoveVirtualSystemResourcesClass
    {
        ManagementObject virtualSystemService = null;
        ManagementScope scope = null;

        RemoveVirtualSystemResourcesClass()
        {
            scope = new ManagementScope(@"root\virtualization", null);
            virtualSystemService = Utility.GetServiceObject(scope, "Msvm_VirtualSystemManagementService");
        }

        ManagementObject GetVirtualSystemEthernetPortSetting(ManagementObject vmSetting, string SyntheticNicElementName)
        {
            ManagementObject SyntheticNicSetting = null;
            ManagementObjectCollection SyntheticNicSettings = vmSetting.GetRelated
            (
             "Msvm_SyntheticEthernetPortSettingData","Msvm_VirtualSystemSettingDataComponent",
                null,
                null,"PartComponent","GroupComponent",
                false,
                null
            );

            foreach (ManagementObject instance in SyntheticNicSettings)
            {
                if (instance["ElementName"].ToString().ToLower() == SyntheticNicElementName.ToLower())
                {
                    SyntheticNicSetting = instance;
                    break;
                }
            }

            return SyntheticNicSetting;

        }

        void RemoveVirtualSystemResources(string vmName, string syntheticNicName)
        {

            ManagementObject vm = Utility.GetTargetComputer(vmName, scope);
            ManagementObject vmSetting = Utility.GetVirtualSystemSettingData(vm);

            ManagementObject syntheticNicPortSetting = GetVirtualSystemEthernetPortSetting(vmSetting, syntheticNicName);

            ManagementBaseObject inParams = virtualSystemService.GetMethodParameters("RemoveVirtualSystemResources");
            inParams["TargetSystem"] = vm.Path.Path;
            string[] resources = new string[1];
            resources[0] = syntheticNicPortSetting.Path.Path;

            inParams["ResourcesettingData"] = resources;

            ManagementBaseObject outParams = virtualSystemService.InvokeMethod("RemoveVirtualSystemResources", inParams, null);

            if ((UInt32)outParams["ReturnValue"] == ReturnCode.Started)
            {
                if (Utility.JobCompleted(outParams, scope))
                {
                    Console.WriteLine("SyntheticNic was removed successfully.");

                }
                else
                {
                    Console.WriteLine("Failed to remove SyntheticNic from VM");
                }
            }
            else if ((UInt32)outParams["ReturnValue"] == ReturnCode.Completed)
            {
                Console.WriteLine("SyntheticNic was removed successfully.");
            }
            else
            {
                Console.WriteLine("Remove SyntheticNic failed with error : {0}", outParams["ReturnValue"]);
            }

            inParams.Dispose();
            outParams.Dispose();
            vm.Dispose();
            vmSetting.Dispose();
            syntheticNicPortSetting.Dispose();
        }

        void Close()
        {
            this.virtualSystemService.Dispose();
        }

        static void Main(string[] args)
        {
            if (args != null && args.Length != 2)
            {
                Console.WriteLine("Usage: RemoveVirtualSystemResources vmName syntheticNicName");
                Console.WriteLine("Example: RemoveVirtualSystemResources MyFirstVM myStaticNic");
                return;
            }

            RemoveVirtualSystemResourcesClass removeResource = new RemoveVirtualSystemResourcesClass();
            removeResource.RemoveVirtualSystemResources(args[0], args[1]);
            removeResource.Close();
        }
    }
}





Viewing all 19461 articles
Browse latest View live




Latest Images