Using the Windows Performance Toolkit


Inside the new Windows Assessment and Deployment Kit (ADK) that was released back in August is a component called the Windows Performance Toolkit.  I’ve talked about this at various events over the past few months, noting that you can use this kit to help identify what is causing your computers to take so long when they start up before they are usable.  But people always ask “how do I do that myself”.  First, I would suggest reviewing the documentation that is available online:

http://msdn.microsoft.com/en-us/library/hh162945

Some of you might have used a previous version of this toolkit, which included tools called XPERF and XPERFVIEW.  This latest version includes new replacement tools (although the old tools are still around for compatibility, for those die-hard users) called the Windows Performance Recorder, WPR.EXE (command line) and WPRUI.EXE (GUI), and the Windows Performance Analyzer, WPA.EXE.  The Recorder captures the events; the Analyzer displays the results.  There is another utility called XBOOTMGR.EXE that takes care of one of the more complicated processes: setting up the computer so that it captures information at boot time.  That’s the one we’ll want to use here.

So let’s assume that you are experiencing a problem with Windows 7 computers starting up slowly.  You can reproduce this at will, but it’s not immediately obvious why.  So you log on to the Windows 7 computer, install the Windows Performance Toolkit redistributable from a computer that has the ADK installed (so we don’t need to put the whole ADK on the Windows 7 computer), and then run the “xbootmgr.exe -trace boot” command to get everything started:

image

It will quickly reboot the computer, so be prepared.  As soon as you can, log in to the computer to finish up the process.  By default, it will wait two minutes to let the system settle down, but you can choose to end it sooner by clicking the “Finish” button:

image

Then you can run the Windows Performance Analyzer to look at the trace; start it using the shortcut on the Start menu.  (Note that it requires .NET 4.0 so if you don’t have that installed it will complain.  You can always analyze the trace remotely if you want, just copy off the *.ETL file.)  Once it launches, have it open the trace file that was created in the same folder we ran XBOOTMGR.EXE from:

image

Since the Windows Performance Analyzer is very graphically-oriented, you might want to do this using a high-resolution display:

image

And that’s really where the fun starts: figuring out what graphs to add, what timeframes to focus on, and trying to get to a root cause.  I’m no expert myself (yet), but I can see from the trace above that most of the time was spent in the Winlogon Init process.  And probably not coincidentally, most of that time corresponds to the gpscript.exe and wscript.exe process lifetimes.  And farther below, we can see generic events from Group Policy that confirm group policy processing took about a minute.  So what was going on in this case?  A bad startup script that took a minute to complete, combined with a policy setting that said “don’t run startup scripts asynchronously”.

Now I just need to teach myself how to better analyze these traces.  Let the fun begin…


Comments (4)

  1. nztakahe says:

    Ask Premier Field Engineer already has some good articles about xperf and troubleshooting boot times.

    blogs.technet.com/…/askpfeplat

  2. Seth says:

    Very nice. I'm going to try this out.

  3. showbox says:

    Thanks for the great info. I really loved this. I would like to apprentice at the same time as you amend your web site, how could i subscribe for a blog site?
    For more info on showbox please refer below sites:
    http://showboxandroids.com/showbox-apk/
    http://showboxappandroid.com/
    Latest version of Showbox App download for all android smart phones and tablets.
    http://movieboxappdownloads.com/ – It’s just 2 MB file you can easily get it on your android device without much trouble. Showbox app was well designed application for android to watch movies and TV shows, Cartoons and many more such things on your smartphone.
    For showbox on iOS (iPhone/iPad), please read below articles:
    http://showboxappk.com/showbox-for-ipad-download/
    http://showboxappk.com/showbox-for-iphone/
    Showbox for PC articles:
    http://showboxandroids.com/showbox-for-pc/
    http://showboxappandroid.com/showbox-for-pc-download/
    http://showboxforpcs.com/
    There are countless for PC clients as it is essentially easy to understand, simple to introduce, gives continuous administration, effectively reasonable. it is accessible at completely free of expense i.e., there will be no establishment charges and after establishment
    it doesn’t charge cash for watching films and recordings. Not simply watching, it likewise offers alternative to download recordings and motion pictures. The accompanying are the strides that are to be taken after to introduce Showbox application on Android.
    The above all else thing to be done is, go to the Security Settings on your Android telephone, Scroll down and tap on ‘Obscure sources’.

  4. aw says:

    hai, I just want to tell you that I am just very new to blogs and seriously loved this website. More than likely I’m planning to bookmark your blog post .
    You amazingly come with really good posts. Thanks a lot for sharing your blog Microsoft.

    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Teknik
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Teknisi
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Televisi
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Teller
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20TNI
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Trans7
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20PLN
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Telkomsel
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Kimia%20Farma
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jakarta%20Selatan
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jakarta%20Pusat
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Jakarta%20Barat
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jakarta%20Timur
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jakarta%20Utara
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Indosat
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20XL%20AXIATA
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Bangka%20Belitung
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Gorontalo
    http://www.lokerjobindo.com/search/label/Loker%20Daera%20Jambi
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jawa%20Barat
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jawa%20Tengah
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Jawa%20Timur
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Kalimantan%20Barat
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Kalimantan%20Selatan
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Kalimantan%20Tengah
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Kalimantan%20Timur
    http://www.lokerjobindo.com/search/label/Loker%20Daerah%20Kalimantan%20Utara
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Sopir
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Statistik
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20swasta
    http://www.lokerjobindo.com/search/label/Lowongan%20Kerja%20Tambang