Applies To: SQL Server 2014, SQL Server 2016 Preview
The sys.traces catalog view contains the current running traces on the system. This view is intended as a replacement for the fn_trace_getinfo function.
For a complete list of supported trace events, see SQL Server Event Class Reference.
This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. Use Extended Event catalog views instead.
Applies to: SQL Server (SQL Server 2008 through current version).
0 = stopped
1 = running
Path of the trace file. This value is null when the trace is a rowset trace.
Maximum trace file size limit in megabytes (MB). This value is null when the trace is a rowset trace.
Time to stop the running trace.
Maximum number of rollover files. This value is null if the Max number is not set.
1 = rowset trace.
1 = rollover option is enabled.
1 = shutdown option is enabled.
1 = default trace.
Number of in-memory buffers used by the trace.
Size of each buffer (KB).
Last trace file position. This value is null when the trace is a rowset trace.
Rowset trace reader session ID. This value is null when the trace is a file trace.
Trace start time.
Time the last event fired.
Total number of events that occurred.
Total number of events dropped.
The visibility of the metadata in catalog views is limited to securables that a user either owns or on which the user has been granted some permission. For more information, see Metadata Visibility Configuration.