質問する質問する
 

回答済みRemove-VM Error (402)

  • 2008年7月11日 6:56JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

     

    Don't ask how I got here, but after an aborted effort to create a Template from an existing VM, I have a VM in the list of SCVMM 2008 Beta 2 that doesn't even have any files left associated with it on the Hyper-V server, but it wont let me remove it.

     

    When I try to remove it from SCVMM, the failure note I get from the Remove-VM job is:

     

    Error (402)

    Library server is not associated with this Virtual Machine Manager server.

    Recommended Action

    Check the library server name, and try the operation again.

     

    Is there some way to for SCVMM to remove this entry from the list?

回答

  • 2008年7月14日 23:33David Armour [MSFT] ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     回答済み

     

    You can use PowerShell to find what LibraryServer the VM is assigned to:

    $VM = Get-VM –Name “ABC123-VM”

    $VM.LibraryServer

     

    My guess is that the LibraryServer property will be null.  I think you may have hit one of our known beta bugs where the LibraryServer property on the VM was not correctly set.

     

    You may want to try Matthew's suggestion in the reply above to get rid of it.

すべての返信

  • 2008年7月11日 12:29Matthew MattoonMVPユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    Hi,

     

    I had a similar problem on SCVMM 2007 with VS.  I ended up recreating the VM on the VS website.  Then using VMM to delete it.  For you I would recommend creating a new VM with the same name using the Hyper-V Manager, then once VMM detects that it is back delete it using VMM.

     

    I don't like that error though.  Have you check all of your agent statuses to ensure that everything is responding?

     

    -matt

  • 2008年7月11日 15:51David Armour [MSFT] ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    Have you tried removing it using PowerShell and the -FORCE parameter?  Sort of like this:

    Get-VMMServer -ComputerName localhost

    $VM = Get-VM -Name "ABC123-VM"

    Remove-VM -VM $VM -Force

     

  • 2008年7月12日 3:45JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    Just tried that, got the same error:

     

    Remove-VM : Library server  is not associated with this Virtual Machine Manager server. (Error ID: 402)

    Check the library server name, and try the operation again.

     

    Any other ideas?

     

    In response to the previous post, this is just a sandbox environment and so will be rebuilt for the final prod implementation and I guess it it beta code, but it would be nice to work out what is going wrong.

     

    Cheers,

    Jeremy.

  • 2008年7月14日 19:58David Armour [MSFT] ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    If you navigate to the Administration Wonderbar in the Admin Console, then select Managed Computers.  What do you see for the status of your Library Server which holds the VM? 

     

  • 2008年7月14日 22:52JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    It shows as "Responding".

     

    The non-existent VM I am trying to remove is on the same box that is my library server is on.

  • 2008年7月14日 23:33David Armour [MSFT] ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     回答済み

     

    You can use PowerShell to find what LibraryServer the VM is assigned to:

    $VM = Get-VM –Name “ABC123-VM”

    $VM.LibraryServer

     

    My guess is that the LibraryServer property will be null.  I think you may have hit one of our known beta bugs where the LibraryServer property on the VM was not correctly set.

     

    You may want to try Matthew's suggestion in the reply above to get rid of it.

  • 2008年7月15日 0:15JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    Correct.  It returns nothing.  Is there a way to set this property?

     

  • 2008年7月15日 0:20David Armour [MSFT] ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    No.  Sorry.

     

  • 2008年7月15日 0:23JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    Yeah I tried

    $VM.LibraryServer='hostanme"

     

    and it said it was a read-only property.

     

     

     

  • 2008年11月6日 14:35PMulhearn ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     

    I'm also seeing this issue in SCVMM 2008 RTM.

     

    I manually moved my default VMM library share to a new 'larger' volume. Didn't realise you have to refresh the library via the UI or powershell for this to take effect.

    When i tried to create a new template, the job fails at "sysprep virtual machine" with the following error:

     

    Error (2912)

    An internal error has occurred trying to contact an agent on the MGT05.mydom.local server.

    (Element not found (0x80070490))

    Recommended Action

    Ensure the agent is installed and running. Ensure the WS-Management service is installed and running, then restart the agent.

     

     

    Now whenever i try to remove the VM (and by force using powershell) I get the Remove-VM 402 error.

     

    I've checked the properties of the VM through powershell and there is no value for 'LibraryServer'.

     

    Is there no other way to forcibly remove the VM from VMM?

  • 2008年11月6日 19:31JeremyHagan ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    In the end I just blew away an rebuilt my VMM server and DB (since I wanted to go from beta to pre-RC anyway).  Not a very useful suggestion, but since VMM doesn't actually hold any volatile data it is always an option as a last resort.

    Cheers,
    Jeremy (formerly known as
    Anony9mous999)
  • 2008年11月15日 3:04Stijn_Verhoeven ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     回答の候補

    Hello

     

    I had the same problem and found a solution that worked for me:

     

    1. go into the VMM database to the table tbl_WLC_VObject, and change the ObjectState field of the problem VM, which problably has the value 104, to value 1

     

    update dbo.tbl_WLC_VObject

    set ObjectState = 1

    where Name = '<VM name>'

     

    2. in VMM admin console, you're VM will now have the status missing, now just delete the VM and it's gone

     

     

     

     

     

    • 回答の候補に設定smurfphy1 2009年3月9日 5:26
    •  
  • 2009年3月2日 16:08Richard Dixon ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    Hello, 
        I just wanted to mentioned that the solution Stijn suggested above corrected my problem i had like this.

    1. go into the VMM database to the table tbl_WLC_VObject, and change the ObjectState field of the problem VM, which problably has the value 104, to value 1

    ** At this point, i went direct to the table and edit the value manually. Of course i did this because this i a Lab environment.

    update dbo.tbl_WLC_VObject
    set ObjectState = 1
    where Name = '<VM name>'

    2. in VMM admin console, you're VM will now have the status missing, now just delete the VM and it's gone.

    - Richard


    Richard Dixon MSFT Sr Systems Engineer
  • 2009年3月9日 5:26smurfphy1 ユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダルユーザーのメダル
     
    Hi all,

    I had very similar problems, my scvmm server rebooted whilst in the middle of creating a VM, which left my VM with an error of "creation failed"  but when I tried to delete it I got an error (see below).  Tried a few solutions, but the one that worked for me was using Richard's solution above.  Thanks all.

    Steve.


    Error (801)

    VMM cannot find VM object .

    Recommended Action

    Ensure the library object is valid, and then try the operation again.