DBCC SHRINKFILE Not Shrinking the Ldf file

  • My Database's ldf file is 20GB and when i run DBCC SHRINKFILE the ldf file does not get reduced it stays at 20GB after execution. The Database is on Simple Recovery Model. Please help.

  • How full's the log? (DBCC SQLPERF(LOGSPACE) )

    What's the open tran info? (DBCC OPENTRAN)

    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
  • Hi,

    I am unable to tel the log size because the ldf files of this database are failing to be attached so that they can be available for browsing, actually i just realised that that is the current problem i am facing.

  • I'm confused. You said that shrinkfile isn't regaining space then you say the log isn't attached.

    Please explain the current situation and what (if anything) you've done so far to the database.

    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
  • i have data.mdf that i need to attach to ssms, when i try to attach this file i get access denied.

    I need to attach this file so that i can be able to run DBCC SHRINKFILE whilst the DB is online offcause.

    How can i attach this file? I tried coping it to another path but it doesnt help, i sitll get access dinied with disk write protected message.

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

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