The size of Tempdb

  • Hello to all,

    My tempdb hace more than 40GB, what can i do? Shrink is peaceful?

    Best Regards,

  • Shrinking the Temp db requires that there is no activity on the temp db which can be difficult on a production server.

    If you are sure there is no activity then you can run

    DBCC SHRINKFILE

    against the Temp Db, this will fail if there is any activity.

    Rather than shrink the temp db you should give it enough room to perform all its tasks, or you will be in the same situaiton in a couple of months time. Unless you have identified a one-off activity that increases its size.

  • Thanks for the quick answer,

    The problem is that tempdb is used all the time in production, maybe at night i could do that... thanks again

  • Hi again,

    How can i know which tables are created on tempdb and aren't used anymore, in sysobjects?

  • carlos.tapadinhas (10/3/2008)


    Hi again,

    How can i know which tables are created on tempdb and aren't used anymore, in sysobjects?

    Answered here:

    http://www.sqlservercentral.com/Forums/Topic580338-146-1.aspx

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply