How to shrink one log file...

  • Hello,

    Can anyone tell me how can i shrink one log file or what is happening so that my transaction log with the following commands does not shrink?

    Commands:

    BACKUP LOG database_name with TRUNCATE_ONLY

    go

    DBCC SHRINKFILE (logfile_name, 1024)

    go

    Thanks and regards,

    JMSM 😉

  • Hi

    Have u tried to change the database mode to simple and then try to truncate the log, or right click on the objecdt explorer and then go to shrink files then shrink it, if it is in full recovery mode, shrinking log files will be a problem

    Cheers

    Suji

  • You can do it easily by making the DB mode to Simple, then shrink the DB and bring it bac to full mode. If you have Log shipping set up, the Log file shouldnt grow.

    If you do not care about log shipping, then why not run it in Simple mode all the time? (It is highly recommended to do Log Shipping)

    Roy Ernest

    -Roy

Viewing 3 posts - 1 through 2 (of 2 total)

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