zoukankan      html  css  js  c++  java
  • Replication--使用备份初始化订阅--推送订阅

    1. 修改发布属性"许从备份文件初始化"置为TRUE
    2. 备份数据库并在订阅服务器上还原
    3. 创建订阅

    ----------------------------------------------------------
    -----------------在发布服务器上运行的脚本-----------------
    use [DB01]
    exec sp_addsubscription
    @publication = N'DB01_REP1',
    @subscriber = N'SQLVM5',
    @destination_db = N'DB01',
    @subscription_type = N'Push',
    @sync_type = N'initialize with backup',
    @article = N'all',
    @update_mode = N'read only',
    @subscriber_type = 0,
    @backupdevicetype='disk',
    @backupdevicename='F:DB01_03.trn'--最后一次备份的备份文件(发布服务器上的存放位置)

    exec sp_addpushsubscription_agent
    @publication = N'DB01_REP1',
    @subscriber = N'SQLVM5',
    @subscriber_db = N'DB01',
    @job_login = null,
    @job_password = null,
    @subscriber_security_mode = 0,
    @subscriber_login = N'sa',
    @subscriber_password = '1234%^&*gg',
    @frequency_type = 64,
    @frequency_interval = 0,
    @frequency_relative_interval = 0,
    @frequency_recurrence_factor = 0,
    @frequency_subday = 0,
    @frequency_subday_interval = 0,
    @active_start_time_of_day = 0,
    @active_end_time_of_day = 235959,
    @active_start_date = 20131028,
    @active_end_date = 99991231,
    @enabled_for_syncmgr = N'False',
    @dts_package_location = N'Distributor'
    GO
     

  • 相关阅读:
    静态库,动态库
    vim
    消息队列-Rabbitmq处理消息及在Spring中的应用
    消息队列 -- 队列(Queue)和主题(Topic)
    Sing的签名算法
    Jquery
    VUE
    node
    vue 加载静态图片
    vue :style 动态绑定style
  • 原文地址:https://www.cnblogs.com/TeyGao/p/3521234.html
Copyright © 2011-2022 走看看