Transaction Log Full

  • My db transaction log is full. I remember with 6.0 there is a command to manual truncate the log. Does anyone know of this command?

    The help suggested that I do a complete backup. I backed up the log file separately and also did a complete backup, but the filesize did not change. I need to shrink the filesize.

    2. How do I change where the database is physically located. I would like to move all my databases to another drive.

    Thanks

  • Which version of SQL Server you are running?

    If it is SQL Server 7.0/2000, See http://support.microsoft.com/default.aspx?scid=kb;en-us;224071

    Backup log yourdbname with truncate_only

    After truncate your log, run DBCC SQLPERF(logspace) to see the spaces usage.

    Backup the log doesn't change the log file size, you have to use DBCC SHRINKFILE command to shrink the file.

    If you are running 6.0, I remember you have to use following command.

    dump transaction yourdbname with truncate_only

  • If you can stop the server, you can deattach the db, copy it to the desire location and then re attach it.

    If not possible, you wan't be able to move the primary files, but you can create new ones and then use dbcc shrinkfile with EMPTYFILE to move the data to new files.

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

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