Trunacate Transaction log file.

  • Hi All,

    backup log with no_log

    dbcc shrinkfile (fileid,truncateonly)

    I would like to know why it is recomended to take full backup

    after this command run.why don't we take only log backup after this command run.

    I am eager t oknow what actually happened in virtual

    log file when transaction is happened.what is save point/min LSN..

    can you please give an idea in detail.

    Thanks,

    Litu

  • This command truncates the log and you will be breaking the log backup chain. In case of any failures you will not be able to restore the log files back in sequence. So, a Diff backup or a full backup is recommended.

    In case a failure happens, you can restore the full followed by a diff and all Tlogs after that. You should **NOT** be Truncating the TLog very often.

  • The above is correct. Once you've done this, you require a full backup to be able to restore. This should not be a standard practice in production. The TRUNCATE ONLY clause should be a rare event because you filled a disk.

  • I am still in confusion..

    can anybody please tell me what actually happens in virtual log when we shrink inactive transaction log.how it affects on log sequence.

    Thanks,

    Litu

  • I did not get any reply.

    I can understand after log trucate full database backup is needed due to log sequence issue.

    but can anybody tell me how does log truncate affect virtual log sequnce.

    Thanks,

    Litu

  • When you shrink a log file, you are removing all inactive virtual logs that do not hold a piece of the logical log. All virtual logs are removed from the end of the log file.

    When you truncate the log you are deleting all inactive virtual logs, regardless if they have been backup up or not.

    More info:

    http://technet.microsoft.com/en-us/library/ms178037.aspx

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

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