Data Synchronization processing (using SQL Server 2000 as an example)

Source: Internet
Author: User
ArticleDirectory
    • Comment
Data Synchronization processing (using SQL Server 2000 as an example)

1. Main Purpose

Data synchronization between two or more servers

2. Method

Use the database replication method to synchronize data through publishing, distribution, and subscription.

3. Steps

1. Configure distribution and release servers (ensure that the server name is not an IP address)

Enterprise Manager-> select a server (take the server named Huiqin as an example)-> tool-> copy

Click the wizard step by step.!After completion,ServerThere will be one more replication Monitor,:


2. Configure related releases, distribution servers, and subscription servers (Point-to-server, and then click Configuration distribution, subscription, and publishing in the tool)

3. Add a new release (step by step)

4. Add a forced subscription (step by step)

5. You can add and synchronize data.

Posted on freeliver54 read (1127) Comments (4) EDIT favorites Overview: MS SQL

Comment # 1st floor [ Landlord ] Freeliver54

Note that the server to be configured is registered
It is best to use the machine name instead of local or IP address 192.168.0.5View reply reference

#2 floor [ Landlord ] Freeliver54

System prompt: sqlserver proxy currently uses the system account, which will cause replication between servers to fail. Please specify another account. However, when users who do not have System Management permissions log on, They configure release and distribution. What is the problem? How can this problem be solved?

This problem occurs because the account used to start the SQLServerAgent service is a system account, the SQLServerAgent Service Startup account must be an operating system account (such as Administrator) with the original system management permissions)

To modify the startup account, run services. MSC, open the Service Manager, find the SQLServerAgent service, double-click the service, select the "Logon" option, change the logon identity to the second option, and enter the Windows Account Name (such as Administrator) with administrator permissions) and the corresponding password. If the password is correct, restart the SQLServerAgent service, and then execute the copied job. View reply reference

# Third floor [ Landlord ] Freeliver54

Test environment:
Two SQL Server 2000 servers, A and B, configure a as the publishing and distribution servers, and B as the subscription Server
The database to be published is db_test, and the publication to be published is table tb_test.
The following steps are completed on:
1. Create a new shared directory as the storage directory of the released snapshot file. The path is D: \ RDATA and the shared directory is named RDATA.

2. Set the SQL Server Agent Service Startup user
Start -- Program -- Management Tools -- services
-- Right-click SQLServerAgent
-- Property -- login -- select "this account"
-- Enter ". \ Administrator" or select another system administrator.
-- Enter the user's password in "password"
3. Set the SQL Server Authentication Mode to solve the permission issues during connection.
Enterprise Manager
-- Right-click an SQL instance -- Properties
-- Security -- Authentication
-- Select "SQL Server and Windows"
-- OK
4. Register with each other on the Publishing Server and subscription Server
Enterprise Manager
-- Right-click the SQL server group
-- Create an SQL Server registration...
-- Next -- available server, enter the name of the remote server you want to register -- add
-- Next -- connect to use, select the second "SQL Server Authentication"
-- Next -- enter the user name and password
-- Next -- select an SQL Server group or create a new group.
-- Next -- complete
Official start:
1. Configure the Publishing Server
A. Select the specified [server] Node
B. Select the [Publish, subscribe server, and distribute] command from the [copy] submenu in the [tools] drop-down menu.
C. In the dialog box that appears, click [next] and follow the prompts.
-- Until "specified snapshot folder"
-- Enter the directory created during preparation in the "snapshot folder": \ A \ RDATA
1. [next] The operation is complete.
D. After setting the Publishing Server, the system will add a replication monitor to the tree structure of the server.
A distribution database (distribution) is also generated)
2. Create a release
A. Select the specified server
B. Select the [create and manage release] command from the [copy] sub-menu in the [tools] menu. At this time, the system will pop up
A dialog box
C. Select database db_test and click [Create release]
D. Click [next] in the prompt dialog box of [Create release wizard]. A dialog box is displayed. Dialog
The content in the dialog box is the three types of replication. Select the first snapshot to publish
E. Click [next] system requirements to specify the database server type that can subscribe to the release, and select Run
"SQL Server 2000" Database Server
F. Click [next] and select the object tb_test to be released.
G. Then [next] until the operation is completed. After the publication is created, the database for creating the publication becomes
A shared database.
---------------------------------------------------------------------------
3. Design subscription
There are two subscription methods: Forced subscription and request subscription.
Follow these steps to force subscription:
Enterprise Manager
-- Copy
-- Publish content
-- Right-click the generated publication
-- Select force New subscription, open the welcome to use force subscription wizard, and click [next]
-- Select Server B and click [next]
-- Enter db_test in "subscribe database name" and click [next]
-- You can schedule the subscription and click [next].
-- Click [next] for the remaining steps until [complete]
The following describes how to request subscription,
A. Select the specified subscription server B.
B. Select [subscribe request] from the [tools] drop-down menu in the [copy] submenu
C. Follow the prompts and click [next] until the system prompts you to check the running status of the SQL Server proxy service.
The precondition for the replication operation is that the SQL Server proxy service must be started.
D. Click [finish] to complete the subscription operation.

How to check whether the configuration is successful:
1. Expand copy under the Publishing Server -- publish content -- Right-click Publish content -- properties -- click live -- status, and then click Run Agent immediately. Then click agent properties, click live tune, and set scheduling. for each day, every minute, between 0:00:00 and 23:59:59.
2. check whether there are more UNC directories in the D: \ RDATA directory.
3. Open B to subscribe to the database, and check whether the subscription table tb_test is added.

The process is really detailed. Thank you! Reply to reference

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.