Need to reduce Initial Size for a DB

  • Hi,

    We gave 1000 MB as Initial Size for a log file while creating DB. We are now facing space issues and we tried to bring down the Initial size of the log file to 500 MB. But it is not working. Can anyone please help on this.

    THanks in Advance!

  • What you mean by initial size?? U created giving that much space..

    You can shrink the transaction log after taking a log backup that wil give you some space

  • you need to use DBCC Shrinkfile

  • HI,

    Initial size for a file will be the same even if we do DBCC shrinkfile. i.e. if i give 100 MB for a logfile and even if the DB is not in use or if it is a blank db it will occupy/assign 100 MB for its log file.

    Hope this helps.

  • dbcc shrinkfile (dbname , targetsize)

    but target size will work only upto the limit you defined for default space.

    Try changing the database recovery to simple and then back to full.

    Also dbcc loginfo(dbname) will give you the active vlfs. the more 2 the less you can shrink.

    if nothing works, check the connection on that database using sp_who2.

    there might be some inactive connection which doing some activity in background and filling log(just a case)

    ----------
    Ashish

  • Hi,

    Thanks to all... dbcc shrinkfile (dbname,target)

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

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