如何缩小日志文件 [英] How to shrink log file

查看:108
本文介绍了如何缩小日志文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

日志重用等待desc显示为日志备份,我无法像为该数据库配置日志传送一样。

Log reuse wait desc showing as log backup and I'm unable to take the same as log shipping is configured for that database.

进行日志备份将破坏LSN链。我该怎么办?

Taking log backup will break the LSN chain. How can I proceed.

谢谢。

推荐答案

logshipping工作正常吗? 

Is logshipping working fine? 

配置的logshipping日志备份的频率是多少?

How frequently log backups happen for your configured logshipping?

我认为通过logshipping配置的日志备份可以帮到你。如果这没有帮助,那么您的logshipping正在遇到问题,或者您的数据库正在承受比正常情况更多的负载。

I think log backups configured through logshipping should help you. If this is not helping then either your logshipping is experiencing issues or your database is experiencing heavy load than normal.

执行以下查询并检查日志备份是否正确发生。

Execute below query and check if log backups are happening properly.

select b.database_name, b.type, bf.physical_device_name, b.backup_start_date, 
b.backup_finish_date, b.backup_size/1024/1024/1024 as Backup_size_in_GB
from msdb..backupset b
left outer join msdb..backupmediafamily bf on bf.media_set_id = b.media_set_id
where b.type in('L') and b.database_name = 'DAtabaseName'
order by b.backup_finish_date desc


这篇关于如何缩小日志文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆