随笔 - 229  文章 - 2  评论 - 511  阅读 - 84万

引起快照重新初始化的原因

1

添加一个article到发布pub1,点击“查看快照代理状态”,发现pub1中所有的aritlce都生成了快照…

在发布库执行

select immediate_sync From syspublications

or

sp_helppublication

发现immediate_sync为1. 将immediate_sync改成0即可:

sp_changepublication  @publication =  'publicationName' 
     ,  
@property =  'immediate_sync' 
     ,  
@value = false 

原因,可能是在添加发布时选中了immediate_sync选项

image

image

 

2

发现某些(事物)发布总是定期(例如每天生成一次快照)生成快照,

在发布服务器上执行sp_helpsubscriberinfo
发现其中一个订阅的frequency_type为4

 

在发布库执行下列语句即可

sp_changesubscriber  @subscriber=  'subscriberservername'
   ,
@frequency_type= 64 

相关解释

[ @frequency_type=] frequency_type

Is the frequency with which to schedule the distribution task. frequency_type is int, and can be one of these values.

Value
Description

1

One time

2

On demand

4

Daily

8

Weekly

16

Monthly

32

Monthly relative

64

Autostart

128

Recurring

posted on   stswordman  阅读(517)  评论(0编辑  收藏  举报
编辑推荐:
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· SQL Server 2025 AI相关能力初探
· AI编程工具终极对决:字节Trae VS Cursor,谁才是开发者新宠?
· 开源Multi-agent AI智能体框架aevatar.ai,欢迎大家贡献代码
· Manus重磅发布:全球首款通用AI代理技术深度解析与实战指南
< 2011年4月 >
27 28 29 30 31 1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
1 2 3 4 5 6 7

点击右上角即可分享
微信分享提示