SQL Server 2008 Replication publication Subscription (data synchronization)

Source: Internet
Author: User
Tags ftp site

Database synchronization Issues

1. There is a primary database server A and another database server B, the client first accesses database B, when the B database server is hung up to access a, when DML operations on database B, while the A is updated, if the communication between A and B fails, the updated data is stored in the temporary table, when the communication is resumed, Automatically update and delete the temporary data, also when B is not available, the data temporarily exists in a, B to restore the connection, a to B update, how to implement?

Database Synchronization Update Step: Mainly uses the MSSQL database replication function (Local publishing and local subscription to complete the primary database server and database server synchronization)

Conditions: 1. Two PC, Environment: Win7 operating system +mssql2008, one PC master database server (publish), another PC to do database server (subscription). Note: 1. Ensure that the MSSQL2008 of both PCs can remotely access each other's database 2. The snapshot file will be saved with FTP (see below)

Start: Start the SQL2008 database service on the primary database server as

Connecting to the SQL2008 server

Create a new database in the SQL2008 database on the primary database server named "Db_test" and a table msgs,msgs the fields in the table as

The database and the table are created well.

Create a local publishing step in replication as follows:

To build an FTP snapshot file, you need to set up an FTP site as follows:

The condition is: To turn on FTP 21 port

1. Start Internet Information Services (IIS) Manager

To continue publishing: Go back to the database---Find the publish "Yangfeizai" action we created

The release is now complete.

Then create the subscription on the database server: steps below

SQL Server 2008 Replication publication Subscription (data synchronization)

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.