Sql-server – How to track if a trace is executing

sql serversql-server-2008-r2trace

I'm sure there's a trace here running and creating logs.

I have no idea who did this in the past ( Its here since my first day in this company ).

There's no trace of it on sp_whoisactive.

Activity monitor shows nothing.

Theres no job running.

There's no job about something like this ( I deleted all old jobs and created my own ones ).

But it's still creating this files. I can't delete if because SQL Server is using it. I can't stop this server because it's the production one. Maybe if I stop the server I can delete the files but they will be created again.

I'm sure there's no sign of a trace running.

enter image description here

This error log file is the same error log we can see on error logs > current

Best Answer

I think the log file you are referencing in your question is created by the SQL Server default trace. You should be able to verify that by running:

SELECT path AS [Default Trace File]
    ,max_size AS [Max File Size of Trace File]
    ,max_files AS [Max No of Trace Files]
    ,start_time AS [Start Time]
    ,last_event_time AS [Last Event Time]
FROM sys.traces
WHERE is_default = 1
GO

There is additional useful information about Different Ways to Find Default Trace Location in SQL Server.