Answered The WSS_Logging database is 4G big!

  • Wednesday, December 16, 2009 10:59 PM
     
     
    After less than 1 month of using Beta2, my WSS_Logging database is full! I'm using a VM with SQL Server 2008 Developer. The database is 4GB big and I can't find anywhere to clean it up.

    Can I just delete tables in that DB?

Answers

  • Thursday, December 17, 2009 11:29 PM
     
     Answered
    You can't delete tables or truncate tables. It is not supported for Sharepoint.

    That database is for logging: usage, ULS etc. The recommandation is to put that db alone on a seperate server, with its own spindle to maximize the perf.

    If you want to reduce the volumn of data goes into that db, diable usage data collection:
    central admin, monitoring, configure usage health data collection, uncheck "enable usage data collection".

    Thanks
    Ying

All Replies

  • Thursday, December 17, 2009 11:48 AM
     
     
    Hi,

    Don't delete
    WSS_Logging – is likely for analytics
    you can stop  Web analytical Data Processing and Web Analytical Web Service
    then check

    Best Regards, Ammar MCT
  • Thursday, December 17, 2009 11:29 PM
     
     Answered
    You can't delete tables or truncate tables. It is not supported for Sharepoint.

    That database is for logging: usage, ULS etc. The recommandation is to put that db alone on a seperate server, with its own spindle to maximize the perf.

    If you want to reduce the volumn of data goes into that db, diable usage data collection:
    central admin, monitoring, configure usage health data collection, uncheck "enable usage data collection".

    Thanks
    Ying
  • Wednesday, December 23, 2009 5:32 PM
     
     
    I was the only one using that development VM for about a month and the logging database was already 4G... I guess Microsoft considers storage to be cheap but it would have been nice to at least have a feature to purge or archive old data...
  • Monday, February 15, 2010 1:19 PM
     
     
    It would be useful to provide a 'non' production scenario to help out on developer workstations.  It is likely they will only locate this thread when it is already too late and they have a massive wss_logging database.

    I found that Shrinking the database can recover around 70% of the space,   as most developers will be turning this off anyway this may be a suitable 'not supported, but ok for dev machines' approach.


    www.21apps.com
  • Thursday, April 15, 2010 6:14 AM
     
     

    I wrote the following SQL script to clean out the tables on my dev box WSS_Logging database:

    DECLARE @TableName AS VARCHAR(MAX)

    DECLARE table_cursor CURSOR
    FOR
     SELECT TABLE_NAME
     FROM INFORMATION_SCHEMA.TABLES
     WHERE TABLE_TYPE = 'BASE TABLE'
     AND TABLE_NAME LIKE '%_Partition%'
    OPEN table_cursor

    FETCH NEXT FROM table_cursor INTO @TableName

    WHILE @@FETCH_STATUS = 0
    BEGIN
     DECLARE @SQLText AS NVARCHAR(4000)
     
     SET @SQLText = 'TRUNCATE TABLE ' + @TableName
     
     EXEC sp_executeSQL @SQLText
     
     FETCH NEXT FROM table_cursor INTO @TableName 
    END

    CLOSE table_cursor
    DEALLOCATE table_cursor

  • Thursday, September 02, 2010 2:35 AM
     
     
    You can't delete tables or truncate tables. It is not supported for Sharepoint.

    That database is for logging: usage, ULS etc. The recommandation is to put that db alone on a seperate server, with its own spindle to maximize the perf.

    If you want to reduce the volumn of data goes into that db, diable usage data collection:
    central admin, monitoring, configure usage health data collection, uncheck "enable divx usage data collection".

    Thanks
    Ying

    I often neglect these, Thanks for your message! I'll follow your instruction.