locked
Can't remove App-V package from server since it is "in use", howto force removal? RRS feed

All replies

  • I see that the links that you have posted contains enough information about stopping the application using Stop-AppVClientPackage & then UnPublish/Remove.

    If not, restart is required for globally published packages & logoff is required for user published packages.

    What exactly are you looking for?


    Posted AS IS with No Warranties. Mark as Answer if this answers your question, It will help other community members.

    Friday, April 1, 2016 12:04 PM
  • >What exactly are you looking for?

    App-V packages are published to users ONLY (no globally published packages). There are 100 users logged on. 1 App-V package is corrupt (it works on other terminal servers correctly). I can't ask 100 users to logoff just because of 1 package.
    I want to stop & force the removal of the package but I cannot because it is in use.


    Jan Hoedt

    Friday, April 1, 2016 12:14 PM
  • What exactly is running in the background even after closing the application. If there is any child process running, you can use TERMINATECHILDREN which will automatically close the child processes when the parent is terminated.

    If the main process itself is still running you either have to use Stop-AppVClientPackage & then Remove-AppVClientPackage. The stop will first close the application forcefully & then remove will work without any issue. It is in-use & that is the reason why you got a warning & so you have to stop to avoid Logoff. Did you received any error when using Stop-AppVClientPackage? If Yes, post more info on what the error is & info from event viewer.

    The other option is to Logoff & Login which you are not ready to go with.


    Posted AS IS with No Warranties. Mark as Answer if this answers your question, It will help other community members.

    Friday, April 1, 2016 1:40 PM
  • >you can use TERMINATECHILDREN

    Where? There is no option in powershell on get-appvclientpackage or stop-appvclientpackage

    >Stop-AppVClientPackage & then Remove-AppVClientPackage.

    If that would work, I wouldn't have made this post.

    >Did you received any error when using Stop-AppVClientPackage?

    No

    >The other option is to Logoff & Login which you are not ready to go with.

    Correct


    Jan Hoedt

    Monday, April 4, 2016 9:45 AM
  • Understand. Give a try with the one below,

    Get-AppvClientPackage -name "packagename" | Stop-AppvClientPackage | Repair-AppvClientPackage | Unpublish-AppvClientPackage | Remove-AppvClientPackage

    Note: Use Global if published Globally.

    TERMINATECHILDREN is the option that has to be set either in AppX Manifest or DeploymentConfig.xml. I would recommend you to use ACE to do this. You will just have to select the main executable whose child processes are still running in the UI of ACE.

    It looks something similar to,

    <TerminateChildProcesses>

      <Application Path="[{ProgramFilesCommonX86}]\AppName\Main.exe" />

    </TerminateChildProcesses>


    Posted AS IS with No Warranties. Mark as Answer if this answers your question, It will help other community members.


    Monday, April 4, 2016 10:18 AM
  • Let me explain you our setup:

    *App-V packages are deployed to users not computers on terminal servers, so -global isn't a relevant option. A few hundred users are working on them. Users on 1 particular server have problems with App-V packages but are not allowed to run Powershell. We are sure the same App-V package works fine on other servers.

    *A repair doesn't work with the App-V GUI, and also not with a script we have enabled for users to repair under their own user context
    "Get-AppvClientPackage -name  $AppVPackage  | Stop-AppvClientPackage | Repair-AppvClientPackage | Out-Null"

    *So I need to remove an App-V package from the server with an administrator account, in order to let the users retrieve a new(correct) one.
    Under administrator context, when I launch get-appvclientpackage * I don't see any App-V package, so I run it with get-appvclientpacage * -all | stop-appvclientpackage | remove-appvclientpackage, a unpublish doesn't make any sense since it isn't published to my user (powershell generates an error on unpublish).

    *I don't get any error, except when I try to remove, then it says "in use".
    If 100 users are logged on, I can't ask them to logoff just because of 1 application. However, it has business impact so it needs to be repaired asap.

    *I had put a server in drain mode an now I was able to remove the App-V package, but the shortcut remained there and it did not reinstall. In Software center it remained "installed". For another server however, this worked fine.

    This App-V 5 in combination with SCCM is totally unmanageable for me. However, the option to go to a management server is not feasable either.

    What you say about ACE, is totally new to me. Never had heard of it.
    Installed the client but do not see what enabling  AppX Manifest or DeploymentConfig.xml would help me "TERMINATECHILDREN" for already deployed appv-packages.

    J.

    Jan Hoedt

    Monday, April 4, 2016 4:57 PM