debuggingwindbg

TTD fails to do selective recording of multiple modules


I use Time-Travel Debugging's TTD.exe utility, and managed to limit it to record a single module using TTD.exe -module option. Now it should be possible to run multiple -module - both TTD.exe doc and TTD.exe's command-line options say that. But when I try, it fails (see output below) - looks like the internal TTDInject.exe doesn't support multiple modules.

Question: How can I get TTD to do selective recording of multiple modules?

Output

D:\ttd> ttd.exe -out d:\ttd -timestampFileName -module ldr.dll -module dicom.dll -monitor mp.exe
(...)
Error text from d:\ttd\mp_2024-08-07_105627.out (see file for full details):

d:\ttd\mp_2024-08-07_105627.out:

Microsoft (R) TTDRecord 1.01.11
Release: 1.11.319.0
Copyright (C) Microsoft Corporation. All rights reserved.


Initializing Time Travel Debugging for Attach to 16816
Time: 08/07/2024 10:56:27
OS:10.0.22631 EDITION:x64

SessionID: B9FB4A55-E12A-4E24-93A2-C2A1A7E01CD8

   (TTD::ManageTTDTrace:2706)
Running 
   (TTD::StartGuestProcess:1479)
Group tracing GUID: E5D1A32D-659A-4A6C-8BDD-BD0BE540B18C

Running "c:\DevTools\devtools\ttd\TTDInject.exe" /duration 0 /InjectMode LoaderForCombinedRecording /ClientParams "31 d:\ttd\mp_2024-08-07_105627.run 0 0 0 0 0 0 1 0 40800801 0" /RecordScenario 268435457 /attach 16816 /SuspendedAtLaunch -TraceFileHandle 4 -GuestEventHandle 8 -ClientEventHandle c -ActiveEventHandle 10 -MutexHandle 14 -CommunicationBufferHandle 18 -SharedSequenceMutexHandle 1c -SharedSequenceBufferHandle 20 /TelemetryFeatureSessionId "B9FB4A55-E12A-4E24-93A2-C2A1A7E01CD8" /SelectiveRecordingModule "ldr.dll" /SelectiveRecordingModule "dicom.dll"
   (TTD::StartGuestProcess:1962)
Microsoft (R) TTDInject Launcher 1.01.11
Release: 1.11.319.0
Copyright (C) Microsoft Corporation. All rights reserved.

Error: Failed to parse command line options
Error: Injecting into guest process failed with exitcode: 1 - 0x1
 This may be an indication of a privileges problem or that the process is
 already under tracing control and needs to be restarted.

   (TTD::StartGuestProcess:2015)
Error: Client initialization failed status:590
   (TTD::InitiateGuestProcess:2524)
Trace dumped to d:\ttd\mp_2024-08-07_105627.run

Solution

  • there was a regression in 1.11.319 that broke module selective recording. If you update to 1.11.410 (current latest version) it should work for you.