Tuesday, October 8, 2013

SharePoint - Logging is not working - logs are empty

Almost every action that occurs in SharePoint is logged. SharePoint stores tons of data into its log file. This log files are very important because every time you get an error on your screen in SharePoint, you get a "Correlation id" on your screen. With this "Correlation id", you can search for detail error description in your logs and this is extremely helpful for resolving that error. SharePoint log files can be found in this path:

C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\LOGS

NOTE: Number "15" in path depends on the version of the SharePoint. If you have SharePoint 2007, then the number is 12. If you have SharePoint 2010, then the number is 14. If you have SharePoint 2013, then the number is 15.


But, sometimes you may ran into situation that logs are created in this folder, but they all have size of 0 byte (which means that nothing is being logged). Something made your logging service to stop.

 
Empty logs created in LOGS folder



There are three thing that you need to check:

1. Check the user permssions for your "SharePoint Tracing Service".

Go to: Start - Administrative Tools - Services - locate "SharePoint Tracing Service".
Make sure that user running this service is a member of Local Administrators group.

2. Restart service from step 1.

3. Free up some disk space.

Now, right  after the restart you may see that there is one log file created (small size, for example 1 KB) and others again have size of 0 byte. Now, open this new small sized log file and you will see the following error in it:

"Not enough free disk space available even if all inactive log files are deleted. The tracing service has temporarily stopped outputting trace messages to the log file. Tracing will resume when more than 1124 MB of disk space becomes available."


It is clear now that you don't have enough free disk space and this is the reason why your logging stopped working in the first place. Make more than 1 GB of free space and your logger will start logging immediately.

5 comments:

  1. Hi Mario
    The user should be a member of "Performance Log Users" group, not the Local Admins.
    Cheers
    Seb

    ReplyDelete
    Replies
    1. Thanks for the info Seb. I will correct it in the post.

      Delete
  2. Thanks for your given information, this stuffs really work. thanks again,

    http://sharepoint.filerepairtool.net

    ReplyDelete
  3. SharePoint database recovery done with this user-friendly tool tool. It will repair your corrupt, damaged SharePoint Server MDF database and recover its objects using Raw and Live SQL Instance mode.

    See more :- http://www.mannatsoftware.com/stellar-phoenix-sharepoint-recovery.html

    ReplyDelete