Microsoft KB Archive/931819

From BetaArchive Wiki
< Microsoft KB Archive
Revision as of 09:26, 21 July 2020 by X010 (talk | contribs) (Text replacement - ">" to ">")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Article ID: 931819

Article Last Modified on 11/30/2007



APPLIES TO

  • Microsoft SoftGrid Application Virtualization for Terminal Services
  • Microsoft SoftGrid Application Virtualization for Windows Desktops



INTRODUCTION

For Microsoft SoftGrid, Process Monitor is the recommended tool to use to troubleshoot the file system and the registry. For more information about Process Monitor, visit the following Microsoft Web site:

However, this article discusses how to use Filemon and Regmon to troubleshoot SoftGrid-enabled applications.

MORE INFORMATION

Summary

This article requires that the user who performs these procedures must be logged on to the SoftGrid client as an account that has local administrator rights. The examples in this article use the default SoftGrid client drive letter Q. Although this article is primarily about Filemon, you can use the same steps for Regmon. To download Sysinternals Filemon and Regmon, visit the following Microsoft Web site:

Configuring the SoftGrid Client

Creating an .osd file

  1. Make a copy of the .osd file for the application that you want to troubleshoot.
  2. Rename the .osd file from {filename}.osd to {filename}_support.osd.
  3. Edit the .osd file by using a text editor.
  4. Change the VERSION attribute of the SOFTPKG element from its current value to Support.

Example: renaming .osd file

Rename ea70.osd to ea70_support.osd
 
<Code>Example: (changing VERSION and SOFTPKG)

From:

<SOFTPKG NAME="SoftGrid Example Application" VERSION="7.0">

To:

<SOFTPKG NAME="SoftGrid Example Application" VERSION="Support">

Creating a .reg file for Filemon

If you use Filemon version 7.00, you can skip this step. For more information about why Sysinternals Filemon and Regmon may not start in the Virtual Environment, click the following article number to view the article in the Microsoft Knowledge Base:

931822 Error message when you try to run the Sysinternals FileMon and RegMon from inside the Microsoft SoftGrid Virtual Environment: "The system cannot find the file specified"


  1. Create a .reg file that is named Filemon.reg.
  2. Edit the .reg file by using a text editor.
  3. Add the following text.

    For Filemon and Regmon version 7.01 and 7.02

    Windows Registry Editor Version 5.00
    
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Filemon701]
    "Type"=dword:00000001
    "ErrorControl"=dword:00000001
    "Start"=dword:00000003
    "ImagePath"="\\??\\c:\\windows\\system32\\drivers\\filem701.sys"
    
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Regmon701]
    "Type"=dword:00000001
    "ErrorControl"=dword:00000001
    "Start"=dword:00000003
    "ImagePath"="\\??\\c:\\windows\\system32\\drivers\\regsys701.sys"

    For Filemon and Regmon version 6.x

    Windows Registry Editor Version 5.00
    
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Filemon]
    "Type"=dword:00000001
    "ErrorControl"=dword:00000001
    "Start"=dword:00000003
    "ImagePath"="\\??\\c:\\windows\\system32\\drivers\\filem.sys"
    
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Regmon]
    "Type"=dword:00000001
    "ErrorControl"=dword:00000001
    "Start"=dword:00000003
    "ImagePath"="\\??\\c:\\windows\\system32\\drivers\\regsys.sys"

    Note In this .reg file, replace "windows" with "winnt" on Windows 2000-based computers.

  4. Save the .reg file

Configuring the .osd file to import the .reg file

If you use Filemon version 7.00, you can skip this step. For more information about why Sysinternals Filemon and Regmon may not start in the Virtual Environment, click the following article number to view the article in the Microsoft Knowledge Base:

931822 Error message when you try to run the Sysinternals FileMon and RegMon from inside the Microsoft SoftGrid Virtual Environment: "The system cannot find the file specified"


  1. Edit the .osd file that you created in the initial step by using a text editor.
  2. Add the following SCRIPT and HREF elements after <DEPENDENCY> but before </DEPENDENCY>.

    <SCRIPT TIMEOUT="60" TIMING="PRE" EVENT="LAUNCH" WAIT="TRUE" PROTECT="FALSE">
    <HREF>%systemroot%\regedit.exe /s filemon.reg</HREF>
    </SCRIPT>
  3. Save the changes to the .osd file.

Example: (adding SCRIPT and HREF elements)

<DEPENDENCY>
<CLIENTVERSION VERSION="2.0.5.0"/>
<SCRIPT TIMEOUT="60" TIMING="PRE" EVENT="LAUNCH" WAIT="TRUE" PROTECT="FALSE">
<HREF>%systemroot%\regedit.exe /s filemon.reg</HREF>
</SCRIPT>
</DEPENDENCY>

Configuring the .osd file to run external applications

Filemon must be run within the Virtual Environment. Otherwise, activity that occurs on the Q drive cannot be monitored.

After you start Filemon, click Volumes, and then click Volume Q: (FIXED). You will receive the following error message:

Filemon could not attach to drive Q:

To run Filemon from the Virtual Environment, you must configure the .osd file to grant access to the Q drive for external applications. To do this, follow these steps:

  1. Edit the .osd file that you created in the initial step by using a text editor.
  2. Add the following script and scriptbody elements after <DEPENDENCY> but before </DEPENDENCY>.

    SCRIPT TIMEOUT="0" TIMING="PRE" EVENT="LAUNCH" WAIT="TRUE" PROTECT="TRUE">
    <SCRIPTBODY>%systemroot%\system32\cmd.exe</SCRIPTBODY>
    </SCRIPT>
  3. Save the changes to the .osd file.

Example

<DEPENDENCY>
<CLIENTVERSION VERSION="2.0.5.0"/>
<SCRIPT TIMEOUT="60" TIMING="PRE" EVENT="LAUNCH" WAIT="TRUE" PROTECT="FALSE">
<HREF>%systemroot%\regedit.exe /s sft_filemon.reg</HREF>
</SCRIPT>
<SCRIPT TIMEOUT="0" TIMING="PRE" EVENT="LAUNCH" WAIT="TRUE" PROTECT="TRUE">
<SCRIPTBODY>%systemroot%\system32\cmd.exe</SCRIPTBODY>
</SCRIPT>
</DEPENDENCY>

Running Filemon within the Virtual Environment

  1. Run the .osd file.


Note When the .reg file opens, the file silently adds itself to the local Registry. The command prompt from the PRE LAUNCH script then appears.

  1. At the command prompt, locate and then run Filemon.exe.
  2. On the File menu, click Capture Events to stop the capturing process.
  3. On the Edit menu, click Clear Display.
  4. On the Volumes menu, click Volume Q: (FIXED).
  5. On the File menu, click Capture Events to start the capturing process.
  6. Close the Command Prompt window.
  7. After you close the Command Prompt window, the application continues to load. When you receive the error message, continue with the next step. If the application does not open without displaying an error message, wait 30 seconds or the time that is typically required for the application to fail. Then continue with the next step.
  8. On the File menu select Capture Events to stop capturing
  9. On the File menu, click Save to save the .log file.
  10. Review the log for potential issues.

'

Tips

  • Do not configure Filemon to filter before capturing the failure. Instead, filter the results after the log is saved.
  • To locate the failure, search for ".wav". When an application fails, it typical calls the critical stop sounds even if the system is not configured for sounds. The failure is typically located several lines above the line that contains ".wav."
  • The key problem results are the following results:
    • FILE NOT FOUND
    • PATH NOT FOUND
    • ACCESS DENIED
  • External applications such as Imasrv.exe ordinarily do not access the Q drive when the problem result is ACCESS DENIED. Applications such as this do not require access to the Q: drive.

    Note Imasrv.exe is the Citrix Independent Management Architecture (IMAService).
  • Compare the log against a Filemon log from a working system. For example, compare the log to a log from a local installation or Sequencer.
  • Not all failures result in an error. During sequencing, the application may use a file from the following path:

    %systemroot%\system32

    However, the application may use that same file from the Q drive during streaming. This may indicate that the version of the file that is on the Q drive must be updated or removed from the package. You can compare the nonworking and the working logs to help determine how to handle the file.

The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, about the performance or reliability of these products.

Keywords: kbexpertiseinter kbhowto KB931819