C2 audit mode can be configured through SQL Server Management Studio or with the c2 audit mode option in sp_configure. Selecting this option will configure the server to record both failed and successful attempts to access statements and objects. This information can help you profile system activity and track possible security policy violations.
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.
Requires membership in the sysadmin fixed server role.
The following example turns on C2 audit mode.
sp_configure 'show advanced options', 1 ; GO RECONFIGURE ; GO sp_configure 'c2 audit mode', 1 ; GO RECONFIGURE ; GO