+ All Categories
Home > Documents > Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Date post: 31-Mar-2015
Category:
Upload: charles-dutt
View: 217 times
Download: 1 times
Share this document with a friend
Popular Tags:
45
Effectively Debugging Complex Application Sequencings Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321
Transcript
Page 1: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Effectively Debugging Complex Application SequencingsKaran DhillonSenior Test LeadMicrosoft Corporation

SESSION CODE: VIR321

Page 2: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Session Objectives And Takeaways

What will not be coveredHow to Sequence an application

What will be coveredHow to diagnose and repair common sequencing challengesLearn how to use procmon for troubleshooting SequencingsMost apps can be sequenced successfully

Page 3: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Best Practices

Know how to install and run the applicationCreate a recipeStart from a clean VM or system image

Revert to clean baseline before sequencingEnterprise image for clientCreate a Q:\ driveUse 8.3 name for package rootConfigure and test the app in the Install Phase

Page 4: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Best Practices

Reserve free space (3x Application size) Adding memory can also help improve sequencing timesDisable Virus Scanners, Defender, Indexing, Microsoft Update during sequencingCreate a dummy ODBC entryCreate a dummy printer entry

Page 5: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Common Sequencing Challenges

Missing filesUnsupported subsystemsInteraction between virtual and native appsSxSDynamic Suite Composition (DSC)

Page 6: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process MonitorLearning The Tool

Page 7: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process Monitor

What is it?An advanced monitoring tool for Windows

File systemRegistryNetworkProcess and thread

Where do I get it?Windows Sysinternals on Microsoft TechNetBing “procmon”

Learn more at Mark Russinovich’s technet blog

Page 8: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Virtual Environment Architecture

Virtual Environment

Virtual Application

Virtual Environment

Virtual Application

Virtual Environment

Virtual Application

Operating System

Page 9: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process MonitorApp-V Integration

procmon /ExternalCapture /NoConnect /BackingFile install.pml

Interface with App-V virtual environment

Do not monitor events on startup

Save events to the PML file

Works with App-V 4.5 and 4.6

Page 10: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process MonitorWorkflow

Start Procmon

MonitorAction

Stop Procmon

Analyze Results

Page 11: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process Monitor – Gotcha

Page 12: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Process Monitor – Gotcha

Click Unblock

Page 13: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Missing FilesUnsupported Subsystems

Troubleshooting Netmon Sequencing

Page 14: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Sequencing Netmon

Karan DhillonTest LeadMicrosoft

DEMO

Page 15: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Missing Files

ExampleVFS Exclusion results in application failure on client

DetectionDialogs from the applicationProcmon analysis

RepairModify VFS Exclusion list and re-sequence

Page 16: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Sequencing ProcessExclusion Items

Excluder ClassifierParser

MonitoredData SFT

Demo-PC→%COMPUTERNAME%C:\Windows → %CSIDL_WINDOWS%Q:\LiveMtg\→ %SFT_MNT%\LiveMtg\C:\Users\Demo\ → %USERPROFILE%…

%CSIDL_INTERNET_CACHE%%CSIDL_LOCAL_APPDATA%C:\$Recycle.Bin\…

%COMPUTERNAME% → App%CSIDL_WINDOWS% → App%SFT_MNT%\LiveMtg\→ App%USERPROFILE% → User…

Page 17: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Unsupported Subsystems

ExampleNetmon installs NM3.sysCOM+DCOM

DetectionDialogs from the applicationApplication knowledgeProcmon analysis

RepairDeploy subsystem out of band on client machinesGuidance for .NET on TechNet

Page 18: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Translucent(Merge, Virtual)

Merge with Local Data

Opaque(Override, Pure Virtual)

Mask Local Data

Reg/FileOpacity

Did registry keyor file path already

exist?

End

No Yes

Sequencing ProcessOpacity

Page 19: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Interaction Between Virtual and Native Apps

Troubleshooting PuTTY Web Site Shortcut

Page 20: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Troubleshooting PuTTY

Karan DhillonTest LeadMicrosoft

DEMO

Page 21: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Interaction Between Virtual and Native Apps

ExampleLaunch of PuTTY website URL launches and exits on clientExisting IE process does not have access to Q: drive

DetectionProcmon analysisVirtual environment policies

RepairModify OSD to launch separate IE process

Page 22: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Putty Website ShortcutOriginal OSD

<CODEBASE HREF="FILE://C:\PUTTY\PUTTY_2.sft" GUID="36C0C5C3-D0BD-4C1E-A918-2684BBD5963B" PARAMETERS="" FILENAME="%SFT_MNT%\PTTY\website.url" SYSGUARDFILE="PTTY\osguard.cp" SIZE="3575538"/>

Modified OSD<CODEBASE HREF="FILE://C:\PUTTY\PUTTY_2.sft" GUID="36C0C5C3-D0BD-4C1E-A918-2684BBD5963B"

PARAMETERS="%SFT_MNT%\PTTY\website.url" FILENAME="%PROGRAMFILES%\Internet Explorer\iexplore.exe"

SYSGUARDFILE="PTTY\osguard.cp" SIZE="3575538"/>

Page 23: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Virtual Environment Policies

•Relaxes isolation for virtual app•Useful when virtual applications need to interact with locally installed applications.

LOCAL_ INTERACTION_

ALLOWEDPolicy

•VIRTUAL_SERVICES_DISABLED•VIRTUAL_REGISTRY_DISABLED

•VIRTUAL_FILE_SYSTEM_DISABLED

Debugging Policies

Page 24: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Exploring SxSTroubleshooting Visual Studio SxS

Page 25: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Troubleshooting Visual Studio SxS

Karan DhillonTest LeadMicrosoft

DEMO

Page 26: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Exploring SxS

Trying to run a simple program from streamed Visual Studio 2008

Page 27: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Exploring SxS

DetectionApplication error message Event logssxstrace

RepairLocal install of runtimes

Page 28: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

SxSTrace

Available starting on VistaFrom an elevated command prompt:

start sxstrace trace –logfile:vs.etlRun app that uses sxsHit Enter in sxstrace window to stopsxstrace parse -logfile:vs.etl -outfile:vs.txt

Page 29: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

SxSTrace Results

Need to install VC library locally

INFO: Resolving reference Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8".…INFO: Resolving reference for ProcessorArchitecture WOW64.…ERROR: Cannot resolve reference Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8".ERROR: Activation Context generation failed.

Page 30: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Dynamic Suite Composition (DSC)

Word Fails to Launch

Page 31: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Word Fails to Launch

DSC Scenario

Word

IMS Plug-in

Primary: Microsoft Office 2007

Secondary: IMS Plug-in

Page 32: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Word Fails to Launch

Launches on SequencerFails to launch on App-V Client

Page 33: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Procmon Analysis

Page 34: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Procmon Analysis

Process Name

Operation Path Result

WINWORD.EXE RegQueryValue HKCR\CLSID\{46D1D082-1C4A-11D4-B46D-0060089D5D78}\InProcServer32\(Default)

SUCCESS Data: C:\PROGRA~1\COMMON~1\IMAGIC~1\WORDCO~1.DLL

WINWORD.EXE CreateFile C:\PROGRA~1\COMMON~1\IMAGIC~1\WORDCO~1.DLL

PATH NOT FOUND

Procmon Forensic Evidence

Page 35: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Word Fails to Launch

Creating the virtual environment

Word

IMS Plug-in

Settings

Primary: Microsoft Office 2007

Secondary: IMS Plug-in

Shared Settings

Page 36: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Word Fails to Launch

WorkaroundUpdate

HKCR\CLSID\{46D1D082-1C4A-11D4-B46D-0060089D5D78}\InProcServer32\(Default)

With%CSIDL_PROGRAM_FILES_COMMON%\Imagic Shared\WordControlDeu.dll

Page 37: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

DSC

ExamplesApp fails to launch

DetectionProcmon analysis

RepairRemove short path names from secondary packagesCopy environment variables and scripts to primary package

Page 38: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Summary

Most apps can be sequenced successfullyProcmon for troubleshootingCommon sequencing challenges

Page 39: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Attachmate Reflection and App-V

Native support of Reflection in App-V formatReflection 2011 Recipe published on TechNetLimited quantity of USB drives in Attachmate boothUSB drives contain Reflection 2011 in native App-V format (.sft)

Page 40: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Virtualization Track ResourcesStay tuned into virtualization at TechEd NA 2010 by visiting our event website, Facebook and Twitter pages. Don’t forget to visit the Virtualization TLC area (orange section) to see product demos, speak with experts and sign up for promotional giveaways.

www.Microsoft.com/Virtualization/Events

www.Facebook.com/Microsoft.Virtualization

Twitter.com/MS_Virt Like this session? Write a blog on 2 key learning's from this session and send it to #TE_VIR and you could win a Lenovo IdeaPad™ S10-3 with Windows 7 Netbook! Review the rules on our event website: Microsoft.com/Virtualization/Events

Page 41: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Related Content

SessionsVIR209 - Microsoft Application Virtualization 4.6 and Microsoft Office 2010VIR11-INT - Top Customer Scenarios and an End-to-End Review of Microsoft Application Virtualization (App-V)VIR320 - Sequencing Deep Dive: Efficiently Making Your Applications VirtualVIR10-INT - When Things Go Wrong: How to Effectively and Efficiently Troubleshoot App-V Deployments

ResourcesMicrosoft Application Virtualization 4.6 Sequencing Guide

http://technet.microsoft.com/en-us/appvirtualization/cc843994.aspx

Page 42: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Complete an evaluation on CommNet and enter to win!

Page 43: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

Resources

www.microsoft.com/teched

Sessions On-Demand & Community Microsoft Certification & Training Resources

Resources for IT Professionals Resources for Developers

www.microsoft.com/learning

http://microsoft.com/technet http://microsoft.com/msdn

Learning

Page 44: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

© 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after

the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

Page 45: Karan Dhillon Senior Test Lead Microsoft Corporation SESSION CODE: VIR321.

JUNE 7-10, 2010 | NEW ORLEANS, LA


Recommended