简体   繁体   中英

Sql Server 2008 Transactional Replication and the Transaction Log

I'm using Transactional Log replication on my sql server 2008 Production db. I'm having issue with Transaction log growing even though I'm backing transactional log every 15 min.
how do i stop the transaction log to grow. I don't want to shrink the log file as it might take log time to shrink since transactions relevant to the publications are still undelivered to the distribution database. Please help

Thanks.

The transaction log size of the publisher database can expand if you are using replication. These transactions, such as uncommitted transactions, are not deleted after checkpoint or after you back up the transaction log until the log-reader task copies the transactions to the distribution database and unmarks them . If an issue with the log-reader task prevents it from reading these transactions in the publisher database, the size of the transaction log may continue to expand as the number of non-replicated transactions increases. You can use the DBCC OPENTRAN Transact-SQL reference to identify the oldest non-replicated transaction.

Ref .

Decreasing the Log Reader Agent's polling interval might help:

Decrease the value of the -PollingInterval parameter for the Log Reader Agent.

The -PollingInterval parameter specifies how often the transaction log of a published database is queried for transactions to replicate. The default is 5 seconds. If you decrease this value, the log is polled more frequently, which can result in lower latency for the delivery of transactions from the publication database to the distribution database. However, you should balance the need for lower latency against the increased load on the server from polling more frequently.

Enhancing Transactional Replication Performance

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM