Hyper-V Zombie Ubuntu Can't Delete or Remove

  1.    #1

    Hyper-V Zombie Ubuntu Can't Delete or Remove


    I am new with Hyper-V, I've been using it to learn Linux/Ubuntu.

    I recently built a new Desktop, installed a Ryzen 7 with 8 cores and 32 Gb RAM. Hyper-V allows me to try different installations without wrestling with the old hardware I had been using.

    The latest installation ran into a problem. Google brought me here, this seems to be the only major support forum where I can find discussion about Hyper-V. I would appreciate any help.

    I have spent a day searching the threads, and spent a couple hours reading some of the tutorials.

    Here is the problem. After a reboot a couple of days ago, I opened the Hyper-V manager and tried to connect to the Ubuntu 18.04.1 that I installed with the Quick Create option. The initial black screen has the message "The virtual machine 'Ubuntu 18.04.1LTS' is starting...".

    That's it. Through many reboots, that is as far as the Ubuntu boot up goes. So I decided to take advantage of the other great option of Hyper-V, and simply delete the virtual machine and start over. I soon find that the Hyper-V management console can't help. There is no option to delete the vm, and apparently nothing I can do with Windows 10 or Hyper-V is able to prevent it from trying to start.

    Google brought me here, and I read through some of the tutorials. PowerShell looked promising, I started it in Administrator mode, and tried the commands --
    Remove-VM 'Ubuntu 18.04.1LTS'
    Stop-VM 'Ubuntu 18.04.1LTS'

    Both commands give me the same error --
    Remove-VM : Deleting 'Ubuntu 18.04.1 LTS' failed.
    The operation cannot be performed while the object is in its current state.


    On the management console, I can "Stop Service".
    I then tried Powershell "Remove VM" again, and got the same error message.

    Does anyone here know of any other method to shut down and/or delete the borked vm?

    I have not tried to go to Control Panel -> Windows Options and remove Hyper-V completely from there. If I do that, and reboot the Computer, then re-activate Hyper-V, will that get rid of the zombie Ubuntu?

    I would appreciate any help
      My ComputerSystem Spec

  2. Kari's Avatar
    Posts : 15,789
    Windows 10 Pro
       #2

    Open an elevated PowerShell, enter the following command and tell what is shown under Status:

    Get-VM 'Ubuntu 18.04.1 LTS'

    Kari
      My ComputerSystem Spec

  3.    #3

    Hi Kari,

    Thanks for stopping by!

    The results are --

    Get-VM : Hyper-V encountered an error trying to access an object on computer 'DESKTOP-6AJLF4H' because the object was
    not found. The object might have been deleted. Verify that the Virtual Machine Management service on the computer is
    running.
    At line:1 char:1
    + Get-VM 'Ubuntu 18.04.1 LTS'
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : ObjectNotFound: (:) [Get-VM], VirtualizationException
    + FullyQualifiedErrorId : ObjectNotFound,Microsoft.HyperV.PowerShell.Commands.GetVM


    Looks like the problem VM is gone. It no longer shows up in the Management Console.

    Apparently when I ran "Stop Service", I can no longer create a new vm. Tried to run Hyper-V Manager as Administrator, and the option to create a new vm is gone. Rebooting Windows does not help.

    Also, I would guess that the virtual Hard Drive is still hanging around until I find and delete it?

    Edit Post:
    -------------
    OK, I went to services.msc and started the Virtual Machine Management Services.
    I ran the command again, and now here is the results:

    PS C:\WINDOWS\system32> Get-VM 'Ubuntu 18.04.1 LTS'

    Name State CPUUsage(%) MemoryAssigned(M) Uptime Status Version
    ---- ----- ----------- ----------------- ------ ------ -------
    Ubuntu 18.04.1 LTS Starting 0 0 00:00:00 Operating normally 9.0


    "Normally" is not what I would call it, it continues to show in the management Console and the Connect window as -->
    "The virtual machine 'Ubuntu 18.04.1. LTS' is starting..."
    Last edited by K E Decilon; 3 Days Ago at 12:35.
      My ComputerSystem Spec


 

Related Threads
NOTE: This guide has been superseded. Just use Quick Create from Hyper-V, select Ubuntu. Here is a quick guide how to run ubuntu 18.04 in enhanced mode in Hyper-V. EDIT: This has now been modified for release version. Please guys, do not...
I am trying to install Ubuntu 1704 through Hyper V. It seems to go easily until I select the command to go ahead and install Ubuntu. Then things go wrong. I get the following error messages as shown in the attachment. It says that file ...
Help with Installing Ubuntu VM in Hyper-v and creating an image as a .WIM within SCCM. So here's a breakdown of the situation: - I need Ubuntu to be installed as a VM on several Windows machines e.g. approximately 90-110 Desktops. - I've...
I recently purchased a Dell XPS 15, 9550, 6700HQ, W10P, 16Gig, non-touch, refurb computer. I re-partitioned the SSD drive, creating among other things drive 'R' of about 97 Gig. R was not reformatted - it is NTFS. Using another computer, I...
Apologies for the very basic question, but this is my first attempt at creating a virtual machine within Windows 10 pro using hyper-v. I have created a VM, and during the process allocated a drive/folder for that VM, and selected the Linux iso file...
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 11:45.
Find Us