shrink fails with error - File ID of database ID cannot be shrunk as it is either being shrunk by another process or is empty

  • This is an fyi (no response necessary).

    I got this error and researched it and found no good answer for how to deal with it:

    [font="Courier New"]"File ID 5 of database ID 8 cannot be shrunk as it is either being shrunk by another process or is empty"[/font]

    One post suggested that it was a memory issue, but it also suggested the only way to deal with it was to restart SQL. I don't have that luxury, so I cleared my cache and reran the shrink and the shrink worked.

    [font="Courier New"]



    Thanks, Deb


  • If Autoshrink is "ON" and you tried to run a "dbcc shrinkfile" you could get that message.

    * Noel

  • See the Connect bug "DBCC SHRINKFILE and SHRINKDATABASE failing after backup" at

  • One more thing to try that worked for me when I received this error message. I just increased the data file by a few MB and then tryed to do the Shrink again. It worked fine. It seems like adding a few MB to the data file resets an internal counter or switch that tells it it's not in the middle of a shrink now.

  • thanks Ted, it worked for me as to find out who is growing my tempdb 1 AM in the morning to rediculas sizes ..

  • Thanks Ted. It works for me, too.:-)

  • Whatta guy, Ted. Bailed me out also.


    “I know that you believe you understand what you think I said, but I'm not sure you realize that what you heard is not what I meant.”...Robert McCloskey


  • Thanks A lot Ted. This worked for me:-).


    Manjunath C Bhat,

    Thanks & Regards,
    Manjunath C Bhat,,

  • More often than not, the best thing to do is to not shrink at all though.

    Kind regards,

    Vegard Hagen
    Norwegian DBA, occasional blogger and generally a nice guy who believes the world is big enough for all of us.
    @vegard_hagen on Twitter
    Blog: Vegards corner (No actual SQL stuff here - havent found my niche yet. Maybe some day...)

    It is better to light a candle than to curse the darkness. (Chinese proverb)
  • Thanks Ted - helped me too!

  • Thanks Ted, it worked for me too.

  • Me also faced the same issue.I increased some MB on the datafile and shrinked.It worked fine for me

  • It worked for me also..

  • For me too.. thanks

  • Thanks Ted, worked for me too

Viewing 15 posts - 1 through 15 (of 33 total)

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