Share via


APPV Troubleshooting ... Demystified !!!

                                                                               TIPS AND TRICKS – TROUBLESHOOTING APPV 

Ever annoyed with the application not working in APPV infrastructure. Here you go few steps to make life easier.

1.        APPV CLIENT TROUBLESHOOTING :

Users not able to see/access application pushed through APPV server in client machine .Below are few steps to crack it.

a.    Log off and Login :

Logoff and log back to the machine so that application is streamed properly from the APPV server to client machine and ready for testing.
Publishing refresh can be configured during APPV client installation or through APPV client console.

b.    Clear APPV Client Cache :

Below are few ways user can clear the APPV cache in client machine and then re-stream/publishing refresh from APPV server for accessing the application or getting updates .

 1 -  Delete all the applications from “Applications” node in APPV client console :

 

  2  -  Delete all the content from %appdata%\SoftGrid Client directory.  
          This clears the APPV user cache..

                                    

                        3 -  Open registry (regedit.exe) with admin credentials and navigate to below hive if present.

                                HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\SoftGrid
                                \4.5\Client\ Applications.
                                Delete all the application entries if available.                                 

                                             

                     3 -    Remove all applications and file types from the Soft Grid cache :

                              Sftmime.exe remove obj:app /global /complete
                              The person running the above command must have administrative rights on the client PC 

                      4 -   Reset the Soft Grid Client Cache to a Clean State :

                              Logon to the client PC with a user account that has administrative rights.
                              Set the following registry value to “0” and Reboot the client PC.
                              HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\SoftGrid\4.5\Client \AppFS\State

                                               
 

                     5  - In case user's virtualized application portfolio is huge then
                           Soft Grid client cache size needs to be increased .

                          Below are the steps to achieve the same.
                           HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\SoftGrid\4.5\Client\AppFS\State
                                     ( Value=0  )
                           HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\SoftGrid\4.5\Client\AppFS\FileSize
                                     ( Value=4096* *Desired maximum cache size in KB )
                           Reboot the client PC for changes to take effect.                

                    Once APPV client cache is cleared User can stream the applications from APPV server by publishing refresh.
                     Below is a snapshot how user can refresh the server

                                      

                     The publishing refresh process can be initiated in three ways:
                            1.  At Login  :  This is the default option selected during App-V Client setup.
                            2.  Manual   :  This can be done thru App-V Client MMC or command line.
                            3.  Periodic :  This allows for DC refreshes to occur in the background at periodic times while the user is logged in.
                      NOTE: The publishing refresh settings can be modified by adjusting the default provider policy in the App-V Management Console.

                      Few other articles which can be helpful: https://blogs.technet.com/b/appv/archive/2009/02/17/a-story-of-a-publishing-refresh-request.aspx

                      Also users can load/refresh the applications using below command lines.
                          Sfttray.exe /refreshall
                          Sfttray.exe /loadall

                       Few other articles which can be helpful: https://technet.microsoft.com/en-us/library/dd835527.aspx

             c.    Repair the virtualized package :

                       In case package is corrupted you need to repair it to fix the virtualized application.
                       When you repair an application, you remove any custom user settings and restore the default settings.
                       This action does not change or delete shortcuts or file type associations, and it does not remove the application from cache.
                       Repair an application
                              1. Move the cursor to the Results pane.
                              2. Right-click the desired application, and select Repair from the pop-up menu.
                              3. At the confirmation prompt, click Yes to repair the application or No to cancel. 

                                               

                              Command Line:    SFTMIME REPAIR APP:application       (where application is the name of the application you want to repair.

              d.     Log file troubleshooting :

                      Below are few log files which can be used for analyzing the errors that occurred during the refresh activity or any other operation.

                      1  -  Sftlog.txt ( SoftGrid Client Log File )

                               Description: The main log used for troubleshooting on the SoftGrid client. Provides general information about App-V Client operations and errors.

                               Path :
                                      Windows XP, Windows Server 2003 : C:\Documents and Settings\All Users\Application Data\Microsoft\Application Virtualization Client
                                      Windows 7 , Windows Vista, Windows Server 2008 : C:\ProgramData\Microsoft\Application Virtualization Client

                               Few other articles which can be helpful: 
                               https://social.technet.microsoft.com/wiki/contents/articles/troubleshooting-some-common-publishing-issues-in-microsoft-app-v.aspx
                               https://support.microsoft.com/kb/931585
                               https://blogs.technet.com/b/virtualworld/archive/2007/08/21/its-all-about-the-logs.aspx
                               https://blogs.technet.com/b/appv/archive/2009/01/26/troubleshooting-app-v-with-log-files.aspx
                               https://blogs.technet.com/b/appv/archive/2007/02/06/some-common-softgrid-errors.aspx

                        2 - Sft-server.log ( SoftGrid Server Log File )

                               Description: Stores messages from the SoftGrid Virtual Application Server.
                               Path: %ProgramFiles%\Softricity\SoftGrid Server\logs

                                Few other articles which can be helpful: https://support.microsoft.com/kb/930871

                        3 - SftMMC.log ( SoftGrid Management Console Log File )

                                 Description: Logs errors that occur within the SoftGrid Management Console.
                                 Path: %ProgramFiles%\Softricity\SoftGrid Management Console\sftMMC.log

                                 Few other articles which can be helpful:  https://support.microsoft.com/kb/930846

2.        TROUBLESHOOTING OSD FILE :

            Most of the time a simple modification to the OSD file can fix the issue and can save lot of time.So you should always edit the OSD file in the App-V client cache on the App-V client machine,
            not on the original package OSD file to quickly apply the alternatives for fixing the issue.

            To find cached OSD for an App-V application, go to the Application Virtualization Client Admin console, highlight the Application node in the left hand pane,
            find the desired application in the right hand pane and double-click on it.
            Find the Local OSD File: parameter on the General Tab and copy the parameter. Open the parameter file in a notepad(Admin).

            notepad C:\Users\Public\Documents\Softgrid Client\SoftGrid Client\OSD Cache\b96b1550-e76f-4ff6-83cb-2d253e6114ed.osd

                                            

                Below is a sample OSD file and its content  .

                                          

              1 . NAME & VERSION :

                     Combination of Application Name + version should be unique in the APPV server database to be properly deployed to the client machine.
                     These values are used to identify the application in the APPV database. The name value will be the name of the displayed icon for the application.

               2 . HREF HOST NAME :

Verify that the SoftGrid server hostname of the HREF path is valid in user’s  target environment. Hostname is resolved at stream time by the 
                      SoftGrid client to locate the SoftGrid server. A specific hostname, FQDN or an environment variable can be used to resolve to a single server or a load balanced farm.

                       HREF="rtsp://Hostname:554/

                       Below is an example of an HREF tag for an actual application where the client has an environment variable set
                       %SFT_SOFTGRIDSERVER%=Dvnserver.corp.msft and the package files are located in .\Content\MerickRIO_TTY_723_MNT\:
                       HREF="rtsp://%SFT_SOFTGRIDSERVER%:554/MerickRIO_TTY_723_MNT/MerickRIO_TTY_723_MNT.sft"

                        Note: The SoftGrid client installer does not set the environment variable 
                                   %SFT_SOFTGRIDSERVER%.

                         If you choose to use this method, the variable can be set through GPO or a login script.
                         

                         You can make sure if user can ping and telnet the server with below commands.
                         Open a command prompt and type below.
                          Ping %SFT_SOFTGRIDSERVER%
                                   - If ping command is successful it will show the reply messages.
                           telnet %SFT_SOFTGRIDSERVER% 554 ( telnet ServerName Port )
                                   - If telnet command is successful the window will be blank.                 

                        Few other articles which can be helpful:
                        https://blogs.technet.com/b/appv/archive/2011/06/02/understanding-the-sft-softgridserver-environmental-variable-in-microsoft-app-v.aspx
                        https://support.microsoft.com/kb/2552111
                        https://support.microsoft.com/kb/930702

                3 . HREF PACKAGE PATH :

Verify that the SoftGrid relative path to SFT file portions of the HREF path are valid in user target environment.
                       The relative path to SFT file is the relative path under the Content repository in which the package directory is located.
                        HREF="rtsp://Hostname:554/<relative path to SFT file>"
                        e.g. HREF="rtsp://%SFT_SOFTGRIDSERVER%:554/MerickRIO_TTY_723_MNT/MerickRIO_TTY_723_MNT.sft"
                        In order to access the package properly there should be a folder named “MerickRIO_TTY_723_MNT” in the content directory 
                        and sft file named “MerickRIO_TTY_723_MNT.sft” under the “MerickRIO_TTY_723_MNT “  folder.

                  4. TERMINATECHILDREN :

                          A virtualized application may not shut down completely when user  exit the application in Microsoft Soft Grid. If a virtualized application fails
                          to shutdown properly or causes anomalies with the OS when the application is shutdown, try setting the following value to TRUE.
                          <VIRTUALENV TERMINATECHILDREN="TRUE">

                          Few other articles which can be helpful: https://support.microsoft.com/kb/931589

                   5.     LOCAL_INTERACTION_ALLOWED :

                           When the value is TRUE , it disables the virtual eventing. This enables creation of named objects (events, mutexes, semaphores, file mappings,
                           and mailslots) and COM objects in the global namespace rather than isolated inside a particular virtual environment,
                           which allows virtual applications to interact with the host operating system's applications. This can solve issues when application interacts with the native client components inappropriately blocked.

                            Few other articles which can be helpful:
                            https://blogs.technet.com/b/appv/archive/2007/09/20/a-look-under-the-covers-the-local-interaction-allowed-tag.aspx
                            https://blogs.technet.com/b/deploymentguys/archive/2011/07/05/allowing-better-interaction-to-app-v-virtual-applications.aspx

                    6. WORKINGDIR :

                             The WORKINGDIR element offers control of the current working directory in virtual environment from within the OSD. 
                             Sometimes the working directory parameter can cause problems, as a test try removing the value altogether.
                             <WORKINGDIR></WORKINGDIR>
                             This is an optional element and is only read by the client.

                              Few other articles which can be helpful:  
                              https://blogs.technet.com/b/virtualworld/archive/2007/11/07/workingdir-examples-specifying-a-working-directory.aspx

                    7.      SUBSYSTEM VALUE :

                              The SubSystem element gives the APP-V client another clue about the type of display that the FILENAME uses so that it can properly launch it.
                              The inline VALUE element indicates if it is a windows or console (DOS).

                               Few other articles which can be helpful:
                               When launching an application virtualized using Microsoft App-V, the application hangs for 10 minutes and then terminates:
                               https://support.microsoft.com/kb/2195120
                               A known good App-V virtual application package may fail with error 19-00001003 after adding a pre-launch script :
                               https://blogs.technet.com/b/appv/archive/2011/10/20/a-known-good-app-v-virtual-application-package-may-fail-with-error-19-00001003-after-adding-a-pre-launch-script.aspx

                   8.       OS VALUE :

                             The OS element is used to specify the operating system the package can run. When no OS tag is included in IMPLEMETATION block,
                              this means the associated .sft can run on any operating system. The values are case sensitive.
                                      < OS VALUE="Win2003TS"/ >
                                      < OS VALUE="WinXP"/ >
                                      < OS VALUE="Win7"/ >

                              Few other articles which can be helpful:
                              https://blogs.technet.com/b/appv/archive/2009/10/29/updated-os-value-xml-tag-reference-and-supported-client-versions.aspx
                              https://blogs.technet.com/b/appv/archive/2008/10/29/error-xxxxxx44-00001007-in-the-sftlog-txt-file.aspx

               Apart from verifying OSD file information inspect the .SPRJ file and verify the <SHORTCUT Path> tag(s) point to the correct names of the OSD file(s) in the package.
              <SHORTCUT Path="TextPad_4.0.7.3.osd"/>

             Few other articles which can be helpful:
              https://blogs.technet.com/b/appv/archive/2012/04/25/app-v-application-is-not-working-as-expected-troubleshooting-check-list.aspx
              https://blogs.technet.com/b/virtualworld/archive/2007/11/14/softgrid-operations-guide-part-1.aspx
              https://support.microsoft.com/kb/940163/
              https://technet.microsoft.com/en-us/library/cc843805.aspx
              https://download.microsoft.com/download/f/7/8/f784a197-73be-48ff-83da-4102c05a6d44/AppPubandClientInteraction.docx

3 .    ADVANCE TROUBLESHOOTING :

         If your package is still not working properly after the above mentioned aforementioned tips and tricks, grab a cup of coffee and try below advanced troubleshooting options . 

         1. Troubleshoot using command prompt or Explorer in APPV bubble :

                Try different alternatives or fixes using different debugging tools in virtual command prompt or check the virtual package contents from virtual explorer and perform fix activities.
                To open a command prompt or explorers in virtual bubble follow below activities.
                Create a shortcut to the virtualized application shortcut in desktop. 

                                          

               Once shortcut is created go to the properties and Edit the shortcut to launch a command prompt inside the App-V bubble.

                                          

                   Right-click on the newly created shortcut on your desktop and choose Properties.Edit the Target: text to include the string /exe cmd.exe between Sfttray.exe and /launch.
                   e.g.                 "C:\Program Files (x86)\Microsoft Application Virtualization Client\sfttray.exe" /exe cmd "Rio 3.6.2010" (If you want to open the virtualized command prompt.)
                                          "C:\Program Files (x86)\Microsoft Application Virtualization Client\sfttray.exe" /exe explorer "Rio 3.6.2010" (If you want to open the virtualized explorer.)

             2 . Startup Process Monitor in virtual bubble :

                 One of the much handy debugging tool to fix the windows/APPV issues is Process Monitor which logs the file system, registry, network activities etc.
                 To open a Process Monitor in virtual bubble follow the below steps :
                 Open the command prompt in the bubble ( check previous section for more information ).
                 From the command prompt, type the full path to Procmon.exe to launch it (for example c:\temp\procmon.exe).Procmon will have full access to changes occurring inside the bubble at this point.

                 ProcMon.exe /externalcapture can be ran directly from Explorer to capture data from applications running under App-V without first launching a command prompt in the bubble.

                                               

              Few other articles which can be helpful:
              https://blogs.technet.com/b/appv/archive/2012/04/24/how-to-run-process-monitor-procmon-inside-the-app-v-virtual-environment.aspx

Hope all these tricks and information will bring every virtualized techy's smile back :) ..... Keep watching for the next post...

Comments

  • Anonymous
    November 21, 2012
    Very nice blog post, I would add this, it is the best App-V error code page I have seen yet, lots of links to content for each error code:App-V Error Codes by Tim Manganwww.app-v.info/app-v_error_codes.html
  • Anonymous
    January 08, 2013
    Hi I have a problem I wondered if you can help me with?I have Adobe Reader Installed locally and Adobe Acrobat Pro X running via App-V.If I click on a pdf file, the App-V Adobe Acrobat Pro X starts but if I click on a pdf via a hyperlink Adobe Reader starts, how can I default hyperlinks to use App-V as well.Many ThanksAny Help Is Grreatly AppreciatedKind RegardsJ
  • Anonymous
    January 21, 2013
    Great post and entry Point for TroubleshootingThanks
  • Anonymous
    October 14, 2013
    Cool staff! I suggest looking to SpyStudio to get user-mode information and to compare virtual and native log.
  • Anonymous
    May 26, 2014
    Hello App-V experts,I support applications for a managed desktop environment and I do not have access to the SoftGrid console.  One of my user's virtualized apps has messed up with some of the registry keys, so I would like to clear the app from local cache so that I can re-stream the app.  I have followed all the steps up to #4 in APPV CLIENT TROUBLESHOOTING section.  The app works after that.  I've also tried a few other apps, they all seem to be running just fine.  However the icons for ALL virt apps have disappeared.Is there any fix for that.App-V client version 4.6.2Any help is appreciated!  Thanks!
  • Anonymous
    September 07, 2014
    Very nice.Truly it is very helpful.
  • Anonymous
    October 13, 2014
    Awesome post. Helps troubleshooting a lot.
  • Anonymous
    October 29, 2014
    I have had the same issue with the icons disappearing. When clearing the AppV User Cache don't delete the Icon Cache and you can avoid that issue. I am not sure of any issues this might introduce, my enviroment has not suffered by leaving this in place.