An ERROR message on the try to shrink the mdf- file

  • Hello ALL,

    Can somebody please help me with the following error message I receive on each try to shrink the first mdf file (approximately 200 GB)

    of a rather large / 800 GB database:

    File ID 1 of database ID 5 cannot be shrunk as it is either being shrunk by another process or is empty.

    Msg 0, Level 11, State 0, Line 0

    A severe error occurred on the current command. The results, if any, should be discarded.

    Some ideas what to do?

    The background - we try to move the extents from the mdf file to the new created ndf files / redistribute the extents. Initially the database was

    constructed of 6 database files - all in one primary group. The files were growing and have now different sizes. The mdf one is the largest. We would like to add database files and in the future work with a database, which will include 16 database files of approximately similar size.

  • That error usually comes up when either the file in question is already in the middle of being shrunk, or when a prior shrink command on it was aborted.

    From an online search of the error, it seems the usual solution has been back up the database and reboot the server.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • Check whther AUTO SHRINK option is turned on for this database or is there anyone else running shrink command on it(check sp_who2 output).

    MJ

  • Thank you for the answer. I will try to execute the steps as soon as I will be able to have a downtime for the production system.

    Regards.

  • Thank you for your answer. I do not really think, AUTOSHRINK is ON. It is very seldom to find the option configured on such class database, but I will check. I also do not think some other user is executing a SHRINK in parallel, as no other user will access the server as administrator.

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

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