-
Notifications
You must be signed in to change notification settings - Fork 180
Description
Some users report getting a "The backing-file for the real-time session "..." has reached its maximum size. As a result, new events will not be logged to this session until space becomes available. This error is often caused by starting a trace session in real-time mode without having any real-time consumers."
I suspect this is due to the buffer size limit set (or rather not set) for the real-time trace session.
PM doesn't set BufferSize, MinimumBuffers or MaximumBuffers when starting a session, so Windows sets this automatically. In this case, Windows sets the following:
- Buffer size: 64 KB
- Minimum buffers: 256
- Maximum buffers: 278
I think we need to increase the sessionProps.MaximumBuffers value prior to StartTraceW call, or do a ControlTraceW( ..., EVENT_TRACE_CONTROL_UPDATE) later.
It might also be good to let the application specify this value via a parameter.