2 SQL Tracefiles on startup

  • Hi Guys

    I have 2 trace jobs running on start up

    1 is the defailt trace file, the other tracefile I cannot see how it starts up

    No SQL scheduled jobs on startup

    No Windows Jobs in Task manager that could start it

    This is SQL2012

    Any suggestions

    Thanks

  • It could be a Stored Procedure set to start running on SQL Server Startup. Try the following query to list all Stored Procedures set to start on SQL Start up.

    Select name, create_date

    From sys.procedures

    Where OBJECTPROPERTY(OBJECT_ID, 'ExecIsStartup')=1;

    GO

    -Regards

  • Nope nothing returned using that query

    The file is called audittrace....

  • Do you have C2 auditing switched on?

  • To check if C2 Audit mode is enables, use the following query:

    Select value

    From sys.configurations

    Where name='c2 audit mode';

    GO

    --Value '1' indicates C2 Audit mode is turned on and '0' indicates it's turned off.

    --Regards

  • Thanks Journey Man it was C2 Auditing.

    🙂

  • You guys wouldn't happen to know if turning it off requires a SQL restart

  • Restart is not required to turn off C2 auditing. To stop C2 audit tracing, set 'c2 audit mode' to 0.

    -Regards

  • alno (3/14/2016)


    You guys wouldn't happen to know if turning it off requires a SQL restart

    Before you turn it off, make sure it isn't required by your company's audit or security policies.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • GilaMonster (3/15/2016)


    alno (3/14/2016)


    You guys wouldn't happen to know if turning it off requires a SQL restart

    Before you turn it off, make sure it isn't required by your company's audit or security policies.

    And if someone turned it on and it isn't causing issues, why turn it off?

  • Drive will run out of Disk Space - which is what happened hence the topic.

    http://www.sqlservercentral.com/Forums/Post.aspx?SessionID=v3es5t45llaie155aorgdb55

    Audit Log File

    C2 audit mode data is saved in a file in the default data directory of the instance. If the audit log file reaches its size limit of 200 megabytes (MB), SQL Server will create a new file, close the old file, and write all new audit records to the new file. This process will continue until the audit data directory fills up or auditing is turned off. To determine the status of a C2 trace, query the sys.traces catalog view.

    Important note Important

    C2 audit mode saves a large amount of event information to the log file, which can grow quickly. If the data directory in which logs are being saved runs out of space, SQL Server will shut itself down. If auditing is set to start automatically, you must either restart the instance with the -f flag (which bypasses auditing), or free up additional disk space for the audit log.

  • Sorry I pasted the wrong Link

    https://msdn.microsoft.com/en-nz/library/ms187634%28v=sql.110%29.aspx

  • Guys

    I turned off C2 Auditing and restarted sql server

    running the script below shows that C2 auditing is turned off - but it is still creating trace files??

    Select value

    From sys.configurations

    Where name='c2 audit mode';

    GO

    Any suggestions

    Thanks

  • Could you give us the results of this query please

    SELECT *

    FROM sys.configurations

    WHERE name = ‘c2 audit mode’

    It sounds like it didn't get switched off, and this should tell us.

  • namevalueminimummaximumvalue_in_usedescriptionis_dynamicis_advanced

    c2 audit mode0010c2 audit mode01

Viewing 15 posts - 1 through 15 (of 19 total)

You must be logged in to reply to this topic. Login to reply