How to diagnose slow booting or logon in Windows? [duplicate]
When I start my PC, it boots into Windows (Windows 7 32-bit) quite happily, I login and the main Windows screen appears. At that point, however, the system is extremely unresponsive for up to 5 minutes - if I click on Firefox to start it, nothing appears to happen for a long time, etc, etc. The mouse and Windows UI is responsive, but programs take forever to start, webpages seem to hang (or at least load extremely slowly) and so on.
I imagine that the issue is with one or more programs that run on startup, but I don't know quite how to identify which one it might be. The event log shows nothing of any obvious interest. I can't see any high CPU activity in task manager or Process Explorer, and I can't hear any high disk activity.
I'd rather understand what's happening and then work out how to address it, than have to go for a blind "switch things off and see what helps" approach, but maybe that's being optimistic :-)
I suspect disk bottlenecks or network, but I don't know how I could set something up to diagnose this (and in particular, given that I can't get programs to start in a timely manner, I'd prefer something that automatically starts and logs data for later analysis than something like Process Explorer, which always leaves me worrying that by the time it started the problem had gone away :-)
I guess my ideal would be 2 things:
Something that gave me an overall "what are the current key bottlenecks in this system" summary (ideally, which could be set to run in the background and collect data for later analysis).
Some means of starting a program (say, Firefox) and have it record what was going on in terms of waits and delays in the system.
Unfortunately, I've never really found anything like either of these.
I'm not a professional systems admin - my background is database admin - so if there are "obvious" tools to look at or try, then I'd be grateful to know of them (particularly if the information they give is easy for an amateur to analyze) :-)
Solution 1:
The tools XPerf and XBootMgr from the WPT (available in Windows SDK or below) are great for troubleshooting any performance related problems on Windows; whether it is at boot or hick-ups during a Full HD video, these tools help you to pinpoint the problem. They are free and from Microsoft. :-)
Performance Analysis
Troubleshooting of slow systems can be done like this:
- Download the setup from Windows Performance Analysis Tools for your Windows version.
- Install the software on your system.
-
Open a command prompt as administrator, and copy paste the next command:
xperf -start perf!GeneralProfiles.InBuffer && timeout -1 && xperf -stop perf!GeneralProfiles.InBuffer myTrace.etl
Press ENTER once to start the command, now you will have to wait till your the action is done.
- Right after your action is done you go to the console and press ENTER.
- After waiting some time a log file myTrace.etl will be produced.
Either analyze this yourself, or if you can't find the issue, upload it and I'll help you:
- Compress this to a zip file, put it online somewhere (perhaps 2shared).
- Share the link here, I will do an attempt to find and show you the cause of your problem.
Boot Analysis
For an user-friendly and simple approach, check @harrymc suggesting Soluto.
For detailed boot analysis, check this document, XBootMgr.exe is available in the WPT I linked earlier.
Following the instructions in the document will result in a similar log which you could analyze or upload...
Solution 2:
UPDATE: Soluto has moved on and its software relates now to the mobile world. Soluto’s original “Anti-Frustration Software” is no longer available from the manufacturer; one would need to look on the Internet for an old version of it, which might not still work after all.
A pity, since it was a rather unique product.
Here is an archived copy of their website. Their URL now redirects to asurion.com, which appears to offer technical services, but no products.
Soluto is an excellent boot-analysis product.
For more info see: Soluto Figures Out What’s Bogging Down Your PC (And Tells You How To Fix It).
Solution 3:
I have an additional suggestion for tracking boot time. It is via Event 100 in Event viewer. Drill down this chain:
Eventvwr
-->Applications and Service Logs
-->Microsoft
-->Windows
-->Diagnostics - performance
-->Operational
-->Event ID 100<--
Then double click on Event 100 which gives you this small window indicating the boot time.
Then click on the 'Details' tab which gives you all this additional information from which you should be able to determine the process which takes the most time during boot.
EventData
BootTsVersion 2
BootStartTime 2015-04-09T15:19:05.671600300Z
BootEndTime 2015-04-09T15:21:34.500099800Z
SystemBootInstance 1174
UserBootInstance 1155
BootTime 24239
MainPathBootTime 12239
BootKernelInitTime 19
BootDriverInitTime 291
BootDevicesInitTime 906
BootPrefetchInitTime 0
BootPrefetchBytes 0
BootAutoChkTime 0
BootSmssInitTime 8551
BootCriticalServicesInitTime 410
BootUserProfileProcessingTime 823
BootMachineProfileProcessingTime 70
BootExplorerInitTime 499
BootNumStartupApps 7
BootPostBootTime 12000
BootIsRebootAfterInstall false
BootRootCauseStepImprovementBits 0
BootRootCauseGradualImprovementBits 0
BootRootCauseStepDegradationBits 0
BootRootCauseGradualDegradationBits 0
BootIsDegradation false
BootIsStepDegradation false
BootIsGradualDegradation false
BootImprovementDelta 0
BootDegradationDelta 0
BootIsRootCauseIdentified false
OSLoaderDuration 1894
BootPNPInitStartTimeMS 19
BootPNPInitDuration 932
OtherKernelInitDuration 411
SystemPNPInitStartTimeMS 1338
SystemPNPInitDuration 265
SessionInitStartTimeMS 1609
Session0InitDuration 4563
Session1InitDuration 553
SessionInitOtherDuration 3434
WinLogonStartTimeMS 10161
OtherLogonInitActivityDuration 686
UserLogonWaitDuration 182