Answered by:
Sharepoint audit log trimming

Question
-
Hi friends,
I have a web application in MOSS 2007 which is audit log enabled. This web app has many site collections and as such the logs generated are huge. The actual problem is we do not want to delete the old logs, but store it in a different shared folder. So, is there a way to automate export of these logs to that folder/any location or site if possible in preferably the same format that is available for export in SharePoint either via an external tool or via coding? (preferably external tool)
Shonilchi..Friday, September 16, 2011 2:12 PM
Answers
-
Hi,
Sharepoint server 2007 diagnostic log settings Uses 4 procedures to configure the diagnostic logging settings.
Refer URL for more detail about the SharePoint server 2007 log settings.
http://technet.microsoft.com/en-us/library/cc262714(office.12).aspx#section4
Also, STSADM command also supports for configuring log. refer the below URL for STSADM command for log setting
http://technet.microsoft.com/en-us/library/cc262191(office.12).aspx
Regardng moving the log from one location to another location, have a windows schedler, which will trigger a batch file process. In the batch file write the command to move the log files from the shared location to other location.
Regards
- Marked as answer by Jinchun ChenMicrosoft employee, Moderator Saturday, October 8, 2011 5:56 AM
Wednesday, September 28, 2011 3:00 AM
All replies
-
Hi,
The best practive for audit log is don't store the log in the same drive of the sharepoint server. Refer the technet URL for best practice of the Audit log
http://technet.microsoft.com/en-us/library/ee748656.aspx#section1
You can use the powershell command to change the log file location
The following PowerShell cmdlet will get all the diagnostic configuration values
Get-SPDiagnosticConfig
If you want to change the location of your diagnostic configuration log use the following PowerShell cmdlet
Set-SPDiagnosticConfig -LogLocation D:SharePointLogs
Regards- Marked as answer by Qiao WeiModerator Friday, September 23, 2011 11:38 AM
- Unmarked as answer by Shonilchi Friday, September 23, 2011 1:24 PM
Saturday, September 17, 2011 5:18 AM -
Hi Nehuraj,
Thanks for the reply, but I am in need of this function for MOSS. and also I would want the logs for some period of time after which it automatically should move to the shared location or to the other location specified.
Shonilchi..Friday, September 23, 2011 1:55 PM -
Hi,
Sharepoint server 2007 diagnostic log settings Uses 4 procedures to configure the diagnostic logging settings.
Refer URL for more detail about the SharePoint server 2007 log settings.
http://technet.microsoft.com/en-us/library/cc262714(office.12).aspx#section4
Also, STSADM command also supports for configuring log. refer the below URL for STSADM command for log setting
http://technet.microsoft.com/en-us/library/cc262191(office.12).aspx
Regardng moving the log from one location to another location, have a windows schedler, which will trigger a batch file process. In the batch file write the command to move the log files from the shared location to other location.
Regards
- Marked as answer by Jinchun ChenMicrosoft employee, Moderator Saturday, October 8, 2011 5:56 AM
Wednesday, September 28, 2011 3:00 AM