We do log backups every 3 minutes but despite that the transaction log has still managed to grow to 200+ gb on disk. Its almost completely empty after log backup. How do you know if your transaction log has become too big and needs shrinking? How do you determine the optimal size?

有帮助吗?

解决方案

Transaction log sizing is important also because of VLF fragmentation which could wreck havoc on your restores and transaction log performance. Ensure your tlog VLF isnt heavily fragmented first I'd say.

Secondly a good way Paul Randal stated was to let your app run natively for a week, and see how big it gets. Make sure you do your regular maintenance on it and such.

Now maybe it gets so big because of ad hoc maintenance, queries, badly written queries, but to find the current good size that would work.

https://www.sqlshack.com/what-is-sql-server-virtual-log-file-and-how-to-monitor-it/

许可以下: CC-BY-SA归因
不隶属于 dba.stackexchange
scroll top