Sql-server – Log file growth issues

sql-server-2008transaction-log

We're consolidating data from a bunch of databases into four reporting databases each night.

Because the entire dataset is imported each night we do not need to be able to restore the data to a point in time. Thus the databases are in simple recovery mode.

Each time we run the import however, our database ldf files grow to absurdly large sizes (50+ Gigs).

Is there a way to turn off the logging altogether or get SQL Server to clear those log files sooner?

I'm guessing no for clearing as the log_reuse_wait_desc is ACTIVE_TRANSACTION.

Best Answer

You can import the data by using operations that can be minimally logged. See Operations That Can Be Minimally Logged and Prerequisites for Minimal Logging in Bulk Import.

And you should consider reducing the duration of transactions during the import. Use batches of limited size and commit periodically.