Unable to Delete Resources: There is currently an active background action

  • From this step, note HostingUnitUid of the Resources that you are trying to delete (highlighted in the preceding screen shot) and then run the following command, substituting HostingUnitUid from your environment:

    Get-ProvTask | Where-Object { $_.ImagesToDelete | Where-Object { $_.HostingUnit -eq “a3284d3e-848c-4f98-ad74-61457b990a7f” } }

    Running the preceding command gives a list of tasks that still need to complete before the Resources can be deleted, and will look similar to the following:

    User-added image

    From the preceding screen shot, it is noticed that the last attempt which was made to delete the disks is in the LastUpdateTime field, and the next attempt that will be made is in the RetryInterval field (specified in hours:minutes:seconds). In this case, the next attempt is made at 10/10/2013 2:48:82 PM.

    To remove this task execute command Remove-ProvTask -TaskID <EnterTaskID>

    If no tasks are listed then all tasks have already been completed. Attempt to remove storage with the following commands:

    Storage :

    Remove-HypHostingUnitStorage -LiteralPath XDHyp:HostingUnitsMyHostingUnit -StoragePath ‘XDHyp:HostingUnitsMyHostingUnitsnewStorage.storage’

    PersonalvDiskStorage:

    Get-ChildItem XDHyp:HostingUnitsMyHostingUnit*.storage | Remove-HypHostingUnitStorage -LiteralPath XDHyp:HostingUnitsMyHostingUnit -StorageType PersonalvDiskStorage

    TemporaryStorage:

    Get-ChildItem XDHyp:HostingUnitsMyHostingUnit*.storage | Remove-HypHostingUnitStorage -LiteralPath XDHyp:HostingUnitsMyHostingUnit -StorageType TemporaryStorage

    Hosting Resource Name

    Remove-Item -path XDHyp:HostingUnitsMyHostingUnit

  • Related:

    • No Related Posts

    Leave a Reply