Log file is big how a delete

  • I all,

    I got a DB in simple recovery mode and the DataAnimalHouse_log.ldf is 80 Gb, data file is DataAnimalHouse.mdf 1 Gb.

    I try to detach for delete log but got an error message:

    TITLE: Microsoft SQL Server Management Studio

    ------------------------------

    The database is in replication and cannot be detached.

    ------------------------------

    How can riduce log file?

    Every nigth make a full BKP...but Logs always increase?

    Alen Italy

  • Chere if there are any open transactions...Did you do any reindexe or index defrag against this db?

    Did you try shrinking it using DBCC SHRINKFILE command? If not try it...

    Check the following link...

    A transaction log grows unexpectedly or becomes full on a computer that is running SQL Server

    http://support.microsoft.com/kb/317375

    MohammedU
    Microsoft SQL Server MVP

  • Hi, I think there is something with replication process.

    Yestarday a reset log but now are 4,9 Gb....

    Pubblisher create a snapshot at the 5:00 AM ...

    I don't understood as can grow so fast.

    The DB on replication is on a simple recovery mode and the replication process is a snapshoot.

    I see on my SUbscriber the type of pubblication is transictional..but isn't 'cause on my Publisher it is snapshot?

    Can U give me some more advice?

    TNKS

  • There are some settings in replication that keep the publisher and subscriber in sync. without going into too much detail check this li

    http://technet.microsoft.com/en-us/library/aa237094(SQL.80).aspxnk out

    Gethyn Elliswww.gethynellis.com

  • Alen cappelletti (6/13/2008)


    Hi, I think there is something with replication process.

    Yestarday a reset log but now are 4,9 Gb....

    Pubblisher create a snapshot at the 5:00 AM ...

    I don't understood as can grow so fast.

    The DB on replication is on a simple recovery mode and the replication process is a snapshoot.

    I see on my SUbscriber the type of pubblication is transictional..but isn't 'cause on my Publisher it is snapshot?

    Can U give me some more advice?

    TNKS

    Yes it sounds like there might be.

    Either way though - detaching the DB and deleting the log is essentially never the right way to go. If you want to truncate of shrink the log then do so from the tools while it's online, but putting the DB in an inconsistent state by just blowing out the log is never a good thing. You're playing with fire that way.

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?

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

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