SymmetricDS同步不完全同步

时间:2017-12-06 13:21:42

标签: synchronization symmetricds

我有一台运行SymmetricDS的3台服务器。假设我有节点1是主节点,节点2.节点3是小节点。

当某些数据被插入到节点2中时,它被同步到节点1,类似地,节点3的数据正在与节点1同步。但是节点2的数据不会进入节点3。 / p>

我不知道在哪里解决这个问题。这是示例配置sql

        -- =========================================
        -- channel starts

        insert into sym_channel
        (channel_id, processing_order, max_batch_size, enabled, description)
        values('acc', 1, 100000, 1, 'account sample');

        -- =========================================
        -- channel ends



        -- =========================================
        -- group starts

        insert into sym_node_group
              (node_group_id, description)
              values ('corp', 'A corporate node');
        insert into sym_node_group
              (node_group_id, description)
              values ('store', 'A retail store node');
        -- group ends
        -- =========================================




        -- =========================================
        -- Group links starts

        insert into sym_node_group_link
        (source_node_group_id, target_node_group_id, data_event_action)
              values ('store', 'corp', 'P');
        insert into sym_node_group_link
        (source_node_group_id, target_node_group_id, data_event_action)
              values ('corp', 'store', 'W');

        -- Group link ends
        -- =========================================



        -- =========================================
        -- trigger starts
        insert into  
        sym_trigger (trigger_id, source_table_name, channel_id, last_update_time,  create_time) 
        values      ('a1',     'acc_asi',        'acc',   current_timestamp, current_timestamp);

        insert into  
        sym_trigger (trigger_id, source_table_name, channel_id, last_update_time,  create_time) 
        values      ('a2',     'acc_lop_asi',        'acc',   current_timestamp, current_timestamp);

        -- =========================================
        -- trigger ends




        -- =========================================
        -- router starts
        insert into sym_router 
        (router_id,source_node_group_id,target_node_group_id,router_type,create_time,last_update_time)
        values('corp_2_store', 'corp', 'store', 'default',current_timestamp, current_timestamp);
        insert into sym_router 
        (router_id,source_node_group_id,target_node_group_id,router_type,create_time,last_update_time)
        values('store_2_corp', 'store', 'corp', 'default',current_timestamp, current_timestamp);
        -- router ends
        -- =========================================



        -- =========================================
        -- trigger router starts

        insert into sym_trigger_router 
        (trigger_id, router_id, initial_load_order, create_time, last_update_time) 
        values ('a1', 'store_2_corp', 1, current_timestamp, current_timestamp);

        insert into sym_trigger_router 
        (trigger_id, router_id, initial_load_order, create_time, last_update_time) 
        values ('a2', 'store_2_corp', 1, current_timestamp, current_timestamp);

        insert into sym_trigger_router 
        (trigger_id, router_id, initial_load_order, create_time, last_update_time) 
        values ('a1', 'corp_2_store', 1, current_timestamp, current_timestamp);

        insert into sym_trigger_router 
        (trigger_id, router_id, initial_load_order, create_time, last_update_time) 
        values ('a2', 'corp_2_store', 1, current_timestamp, current_timestamp);

        -- =========================================
        -- trigger router ends

如果我知道如何将节点2的数据推送到节点3,或者节点2在节点1上推送数据然后节点1将这些数据推送到节点3,那将非常有用

此致

尼克松

1 个答案:

答案 0 :(得分:1)

sym_trigger的列sync_on_incoming_batch设置为1,以便从2到3同步所需的表,反之亦然,通过主1。