<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8113842713358083384</id><updated>2011-04-21T13:26:47.479-07:00</updated><category term='MSSQL 2005'/><title type='text'>database-studying</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://database.trauvang.net/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8113842713358083384/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://database.trauvang.net/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>BUFFALO</name><uri>http://www.blogger.com/profile/09155766466641361291</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='22' height='32' src='http://1.bp.blogspot.com/_ne3ScYcCW08/SWcMSMSTyCI/AAAAAAAAAxk/wxoKt97Ocg0/S220/Trau_KhacGo.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>1</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8113842713358083384.post-1945258153343950142</id><published>2009-01-12T19:40:00.000-08:00</published><updated>2009-01-12T22:41:02.630-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MSSQL 2005'/><title type='text'>C2 Audit Mode</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;Microsoft® SQL Server includes a C2 Audit Mode that can be configured through SQL Server Management Studio or with the stored procedure sp_configure. Selecting this option configures the server to record both successful and unsuccessful attempts to access statements and objects.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;C2 Audit Mode always enables all event classes in the Security Audit category. For most production sites, auditing all event classes results in an unacceptable performance degradation of the SQL Server. If you use C2 Audit mode, do not enable all event classes.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;For MS SQL 2005, C2 Audit Mode data is saved in a file in the \MSSQL\Data directory of default instances, and the \MSSQL$instancename\Data directory of named instances. When the audit log file reaches its size limit of 200 MB, the SQL Server creates a new file, closes the old file, and writes all new audit records to the new file. This auditing process continues until the audit data directory fills up or auditing is turned off.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-size:100%;" &gt;&lt;span style="font-family:arial;"&gt;Important:&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;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, the SQL Server shuts 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.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-size:100%;" &gt;&lt;span style="font-family:arial;"&gt;Enabling C2 Audit Mode&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;Enabling the C2 audit mode parameter in SQL Server 2005:&lt;br /&gt;&lt;br /&gt;  1. Connect to SQL Server 2005 using the SQL Server Management Studio.&lt;br /&gt;  2. In the Object Explorer pane, right-click a [server] , and then select Properties .&lt;br /&gt;  3. In the Server Properties window, select the Security page.&lt;br /&gt;  4. In the details pane, select the Enable C2 audit tracing check box.&lt;br /&gt;  5. Click OK to close the Server Properties window.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;You must be a member of the sysadmin fixed server role to perform this procedure.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;1.    Run the stored procedure sp_configure with Advanced Options enabled followed by the RECONFIGURE command: &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;2.    sp_configure 'show advanced options', 1;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;3.    RECONFIGURE&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;4.    To enable auditing, run sp_configure with the c2 audit mode parameter set to 1: &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;5.    EXEC sp_configure 'c2 audit mode', 1&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;RECONFIGURE&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;6.    After changing the C2 audit mode setting, restart the server.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-size:100%;" &gt;&lt;span style="font-family:arial;"&gt;Note:&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-family:arial;"&gt;If you have enabled C2 auditing, you might want to disable login auditing on the Security tab of the SQL Server Properties window in SQL Server Enterprise Manager (described previously). If you do not disable this feature, the auditing functions record the same type of event twice, unnecessarily degrading server performance.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8113842713358083384-1945258153343950142?l=database.trauvang.net' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://database.trauvang.net/feeds/1945258153343950142/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://database.trauvang.net/2009/01/c2-audit-mode.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8113842713358083384/posts/default/1945258153343950142'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8113842713358083384/posts/default/1945258153343950142'/><link rel='alternate' type='text/html' href='http://database.trauvang.net/2009/01/c2-audit-mode.html' title='C2 Audit Mode'/><author><name>BUFFALO</name><uri>http://www.blogger.com/profile/09155766466641361291</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='22' height='32' src='http://1.bp.blogspot.com/_ne3ScYcCW08/SWcMSMSTyCI/AAAAAAAAAxk/wxoKt97Ocg0/S220/Trau_KhacGo.jpg'/></author><thr:total>0</thr:total></entry></feed>
