Showing posts with label synchronization. Show all posts
Showing posts with label synchronization. Show all posts

Friday, March 30, 2012

merge replication, subscriber can only download but not upload?

Hi,

I need a urgent help! The problem is that every synchronization only transfer data from subscriber to publisher, but not the other direction. The publisher is sql server 2005 standard edition, and the subscriber is 2005 express. Is that any stored-procedure to deal with such a problem?

Thanks for any commnet.
can you describe your problem in more detail - is this a filtered publication, or are there any other publication/article properties that are set that we should know of? Can you describer the changes made at the publisher that should be arriving at the subscriber?|||Thx for reply.

The publication is not filtered, and just a normal, standard merge replication. The situation is that I prepared each subscriber locally with the publisher, and they were running well when testing. After that, I took them to different remote locations. The subscribers now are communicating with the publisher by adsl VPN tunnel. What happened is that some of the subscribers only can download changes from the publisher, but cannot upload the changes to the publisher. So what i can do is to delete the subscriptions and re-create them. After that, they are working well.

I really want to know what on earth the problem is.

Thx for any consideration.

|||

Heloo WII,

There is an option which is like "Subscribers download-only, prohibit changes" while creating the publication.

Its default is "Bidirectional".

The Merge Agent which is at the subscriber may not be working. Check out its History by clicking on its job and selecting View History.

Ekrem ?nsoy

|||Thanks, Ekrem.

But most of other subscribers can upload changes to the publisher. So I'm really confused what's going on with the ones that not working properly.

BTW, does the replication on SQL 2005 express change a lot? 'coz our system is working fine with the combination of sql server 2000 standard & MSDE.

Anyone can recommend some articles or books about the sql server 2005 merge replication? the more detailed the better.

Thanks a lot.
|||

No. You will see virtually the same thing regardless of whether it is Express Edition, Workgroup, Standard, etc. You're going to have to provide a lot more detail on this.

1. What is your configuration

2. Are the subscribers actually connecting to the publisher and staying connected long enough to complete a synch cycle (upload first, resolve conflicts, and then download changes)

3. Are there any error messages

The more information that you give us, the better we can help.

|||Thanks Michael,

Because I'm new to SQL Server, actually I'm quite clear where to find the useful information. so sorry about that.

1. I'm using pull replication, non-filtered publication.

2.yes, i think so. the publisher and subscribers are connected by dedicated VPN tunnels.

3.yes, heaps....after each synchronization, each subscriber got the same error message "The process was successfully stopped. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147200963). Get help: http://help/MSSQL_REPL-2147200963".
And in the SQL Server Log, i can find such kind of error message "Subscriber 'xxx' subscription to article 'docket_items' in publication 'yyy' failed data validation." Even I re-created the subscription from the scratch, it still came out. So I guess something wrong with the publisher?
|||We're going to need a lot more information than you could possible add to a forum post. Please open a support case with Microsoft and be prepared to send them backups of the publisher, subscriber, msdb, and distribution databases along with error logs and event logs. They'll have more specific information as well when you get to a support engineer.|||Thanks Michael, thank you so much.

I think you are right. I'll do that.

Thanks for all the comments.
|||Hi guys,

I finally found out the error messages though the verbose log.

Here is part of it:

2007-05-18 11:01:57.062 Percent Complete: 0
2007-05-18 11:01:57.062 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Data validation failed for one or more articles. When troubleshooting, check the output log files for any errors that may be preventing data from being synchronized properly. Note that when error compensation or delete tracking functionalities are disabled for an article, non-convergence can occur.
2007-05-18 11:01:57.140 Percent Complete: 0
2007-05-18 11:01:57.140 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'cash_breakup' failed data validation (rowcount and checksum). Rowcount actual: 268, expected: 0.
2007-05-18 11:01:57.218 Percent Complete: 0
2007-05-18 11:01:57.218 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_canceled' failed data validation (rowcount and checksum). Rowcount actual: 17, expected: 0.
2007-05-18 11:01:57.281 Percent Complete: 0
2007-05-18 11:01:57.296 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_reprinted' failed data validation (rowcount and checksum). Rowcount actual: 484, expected: 0.
2007-05-18 11:01:57.375 Percent Complete: 0
2007-05-18 11:01:57.375 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'banked_amounts' failed data validation (rowcount and checksum). Rowcount actual: 2224, expected: 0.
2007-05-18 11:01:57.453 Percent Complete: 0
2007-05-18 11:01:57.453 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_payments' failed data validation (rowcount and checksum). Rowcount actual: 8732, expected: 0.
2007-05-18 11:01:57.546 Percent Complete: 0
2007-05-18 11:01:57.546 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'credit_notes' failed data validation (rowcount and checksum). Rowcount actual: 856, expected: 0.
2007-05-18 11:01:57.625 Percent Complete: 0
2007-05-18 11:01:57.625 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'gift_vouchers' failed data validation (rowcount and checksum). Rowcount actual: 605, expected: 0.
2007-05-18 11:01:57.703 Percent Complete: 0
2007-05-18 11:01:57.703 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'laybys' failed data validation (rowcount and checksum). Rowcount actual: 576, expected: 0.
2007-05-18 11:01:57.781 Percent Complete: 0
2007-05-18 11:01:57.781 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'store_received_in' failed data validation (rowcount and checksum). Rowcount actual: 1107, expected: 0.
2007-05-18 11:01:57.859 Percent Complete: 0
2007-05-18 11:01:57.859 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'customers' failed data validation (rowcount and checksum). Rowcount actual: 4748, expected: 0.
2007-05-18 11:01:57.953 Percent Complete: 0
2007-05-18 11:01:57.953 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'stations' failed data validation (rowcount and checksum). Rowcount actual: 28, expected: 0.
2007-05-18 11:01:58.015 Percent Complete: 0
2007-05-18 11:01:58.015 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'dockets' failed data validation (rowcount and checksum). Rowcount actual: 14389, expected: 0.
2007-05-18 11:01:58.093 Percent Complete: 0
2007-05-18 11:01:58.093 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_items' failed data validation (rowcount and checksum). Rowcount actual: 12414, expected: 0.
2007-05-18 11:01:58.171 Percent Complete: 0
2007-05-18 11:01:58.171 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'stocktake_items' failed data validation (rowcount and checksum). Rowcount actual: 80076, expected: 0.
2007-05-18 11:01:58.250 Percent Complete: 0
2007-05-18 11:01:58.250 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'store_received_items' failed data validation (rowcount and checksum). Rowcount actual: 25773, expected: 0.
2007-05-18 11:01:58.296 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.296 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.296 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.328 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.328 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.328 The merge process could not set the status of the subscription correctly.
2007-05-18 11:01:58.343 OLE DB Subscriber 'SURF-PSS1': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
2007-05-18 11:01:58.343 [100%] Percent Complete: 100
2007-05-18 11:01:58.343 The process was successfully stopped.
2007-05-18 11:01:58.343 OLE DB Distributor 'SURF-SERVER': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
2007-05-18 11:01:58.484 The Merge Agent was unable to update information about the last synchronization at the Subscriber. Ensure that the subscription exists at the Subscriber, and restart the Merge Agent.
2007-05-18 11:01:58.578 Percent Complete: 0
2007-05-18 11:01:58.578 Category:NULL
Source: Merge Replication Provider
Number: -2147200963
Message: The process was successfully stopped.
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.593 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.593 Disconnecting from OLE DB Distributor 'SURF-SERVER'

|||These are the articles that failed the data validation, and there are much more other articles passed the data validation.

I'm just wondering that why not keep replicating when the row count is different between the subscriber and the publisher. isn't the replication's purpose to make them same?

I'll appreciate any comment. Thank you. I'm really desperate now.
|||

If you do not care about the validations, then you should look at your merge agent job and remove tihs part:

"-Validate 3". What this tells the merge agent is to do a validation and stop if there are errors.

Remove this and it will continue to pass.

However please do look at the real reason why there are differences between the publisher and the subscriber in the first place.

|||Thanks Mahesh,

I did put that parameter in the script.

Thank you very much!

merge replication, subscriber can only download but not upload?

Hi,

I need a urgent help! The problem is that every synchronization only transfer data from subscriber to publisher, but not the other direction. The publisher is sql server 2005 standard edition, and the subscriber is 2005 express. Is that any stored-procedure to deal with such a problem?

Thanks for any commnet.
can you describe your problem in more detail - is this a filtered publication, or are there any other publication/article properties that are set that we should know of? Can you describer the changes made at the publisher that should be arriving at the subscriber?|||Thx for reply.

The publication is not filtered, and just a normal, standard merge replication. The situation is that I prepared each subscriber locally with the publisher, and they were running well when testing. After that, I took them to different remote locations. The subscribers now are communicating with the publisher by adsl VPN tunnel. What happened is that some of the subscribers only can download changes from the publisher, but cannot upload the changes to the publisher. So what i can do is to delete the subscriptions and re-create them. After that, they are working well.

I really want to know what on earth the problem is.

Thx for any consideration.

|||

Heloo WII,

There is an option which is like "Subscribers download-only, prohibit changes" while creating the publication.

Its default is "Bidirectional".

The Merge Agent which is at the subscriber may not be working. Check out its History by clicking on its job and selecting View History.

Ekrem ?nsoy

|||Thanks, Ekrem.

But most of other subscribers can upload changes to the publisher. So I'm really confused what's going on with the ones that not working properly.

BTW, does the replication on SQL 2005 express change a lot? 'coz our system is working fine with the combination of sql server 2000 standard & MSDE.

Anyone can recommend some articles or books about the sql server 2005 merge replication? the more detailed the better.

Thanks a lot.
|||

No. You will see virtually the same thing regardless of whether it is Express Edition, Workgroup, Standard, etc. You're going to have to provide a lot more detail on this.

1. What is your configuration

2. Are the subscribers actually connecting to the publisher and staying connected long enough to complete a synch cycle (upload first, resolve conflicts, and then download changes)

3. Are there any error messages

The more information that you give us, the better we can help.

|||Thanks Michael,

Because I'm new to SQL Server, actually I'm quite clear where to find the useful information. so sorry about that.

1. I'm using pull replication, non-filtered publication.

2.yes, i think so. the publisher and subscribers are connected by dedicated VPN tunnels.

3.yes, heaps....after each synchronization, each subscriber got the same error message "The process was successfully stopped. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147200963). Get help: http://help/MSSQL_REPL-2147200963".
And in the SQL Server Log, i can find such kind of error message "Subscriber 'xxx' subscription to article 'docket_items' in publication 'yyy' failed data validation." Even I re-created the subscription from the scratch, it still came out. So I guess something wrong with the publisher?
|||We're going to need a lot more information than you could possible add to a forum post. Please open a support case with Microsoft and be prepared to send them backups of the publisher, subscriber, msdb, and distribution databases along with error logs and event logs. They'll have more specific information as well when you get to a support engineer.|||Thanks Michael, thank you so much.

I think you are right. I'll do that.

Thanks for all the comments.
|||Hi guys,

I finally found out the error messages though the verbose log.

Here is part of it:

2007-05-18 11:01:57.062 Percent Complete: 0
2007-05-18 11:01:57.062 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Data validation failed for one or more articles. When troubleshooting, check the output log files for any errors that may be preventing data from being synchronized properly. Note that when error compensation or delete tracking functionalities are disabled for an article, non-convergence can occur.
2007-05-18 11:01:57.140 Percent Complete: 0
2007-05-18 11:01:57.140 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'cash_breakup' failed data validation (rowcount and checksum). Rowcount actual: 268, expected: 0.
2007-05-18 11:01:57.218 Percent Complete: 0
2007-05-18 11:01:57.218 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_canceled' failed data validation (rowcount and checksum). Rowcount actual: 17, expected: 0.
2007-05-18 11:01:57.281 Percent Complete: 0
2007-05-18 11:01:57.296 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_reprinted' failed data validation (rowcount and checksum). Rowcount actual: 484, expected: 0.
2007-05-18 11:01:57.375 Percent Complete: 0
2007-05-18 11:01:57.375 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'banked_amounts' failed data validation (rowcount and checksum). Rowcount actual: 2224, expected: 0.
2007-05-18 11:01:57.453 Percent Complete: 0
2007-05-18 11:01:57.453 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_payments' failed data validation (rowcount and checksum). Rowcount actual: 8732, expected: 0.
2007-05-18 11:01:57.546 Percent Complete: 0
2007-05-18 11:01:57.546 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'credit_notes' failed data validation (rowcount and checksum). Rowcount actual: 856, expected: 0.
2007-05-18 11:01:57.625 Percent Complete: 0
2007-05-18 11:01:57.625 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'gift_vouchers' failed data validation (rowcount and checksum). Rowcount actual: 605, expected: 0.
2007-05-18 11:01:57.703 Percent Complete: 0
2007-05-18 11:01:57.703 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'laybys' failed data validation (rowcount and checksum). Rowcount actual: 576, expected: 0.
2007-05-18 11:01:57.781 Percent Complete: 0
2007-05-18 11:01:57.781 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'store_received_in' failed data validation (rowcount and checksum). Rowcount actual: 1107, expected: 0.
2007-05-18 11:01:57.859 Percent Complete: 0
2007-05-18 11:01:57.859 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'customers' failed data validation (rowcount and checksum). Rowcount actual: 4748, expected: 0.
2007-05-18 11:01:57.953 Percent Complete: 0
2007-05-18 11:01:57.953 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'stations' failed data validation (rowcount and checksum). Rowcount actual: 28, expected: 0.
2007-05-18 11:01:58.015 Percent Complete: 0
2007-05-18 11:01:58.015 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'dockets' failed data validation (rowcount and checksum). Rowcount actual: 14389, expected: 0.
2007-05-18 11:01:58.093 Percent Complete: 0
2007-05-18 11:01:58.093 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'docket_items' failed data validation (rowcount and checksum). Rowcount actual: 12414, expected: 0.
2007-05-18 11:01:58.171 Percent Complete: 0
2007-05-18 11:01:58.171 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'stocktake_items' failed data validation (rowcount and checksum). Rowcount actual: 80076, expected: 0.
2007-05-18 11:01:58.250 Percent Complete: 0
2007-05-18 11:01:58.250 Category:NULL
Source: Merge Process
Number: -2147200953
Message: Article 'store_received_items' failed data validation (rowcount and checksum). Rowcount actual: 25773, expected: 0.
2007-05-18 11:01:58.296 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.296 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.296 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.312 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.328 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.328 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.328 The merge process could not set the status of the subscription correctly.
2007-05-18 11:01:58.343 OLE DB Subscriber 'SURF-PSS1': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
2007-05-18 11:01:58.343 [100%] Percent Complete: 100
2007-05-18 11:01:58.343 The process was successfully stopped.
2007-05-18 11:01:58.343 OLE DB Distributor 'SURF-SERVER': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
2007-05-18 11:01:58.484 The Merge Agent was unable to update information about the last synchronization at the Subscriber. Ensure that the subscription exists at the Subscriber, and restart the Merge Agent.
2007-05-18 11:01:58.578 Percent Complete: 0
2007-05-18 11:01:58.578 Category:NULL
Source: Merge Replication Provider
Number: -2147200963
Message: The process was successfully stopped.
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Subscriber 'SURF-PSS1'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.578 Disconnecting from OLE DB Publisher 'SURF-SERVER'
2007-05-18 11:01:58.593 Disconnecting from OLE DB Distributor 'SURF-SERVER'
2007-05-18 11:01:58.593 Disconnecting from OLE DB Distributor 'SURF-SERVER'

|||These are the articles that failed the data validation, and there are much more other articles passed the data validation.

I'm just wondering that why not keep replicating when the row count is different between the subscriber and the publisher. isn't the replication's purpose to make them same?

I'll appreciate any comment. Thank you. I'm really desperate now.
|||

If you do not care about the validations, then you should look at your merge agent job and remove tihs part:

"-Validate 3". What this tells the merge agent is to do a validation and stop if there are errors.

Remove this and it will continue to pass.

However please do look at the real reason why there are differences between the publisher and the subscriber in the first place.

|||Thanks Mahesh,

I did put that parameter in the script.

Thank you very much!

Wednesday, March 28, 2012

Merge Replication with Restore Database

hi all,
We currently encounter a big trouble:
We have set up a model of synchronization from PDA to SQL Server
succesfully. Everything is OK until SQL Server database met a trouble
and needed to restore database. We restored a rather old database (1
week ago) and then so many erros appeared. Database that is in PDA
contains much newer data than on SQL Server. When we synchorize, it
appeared error 28549: "The row update or insert cannot be reapplied due
to an integrity violation".
I would like to ask whether there is a standard process for Merge
Replication in case of restoring old database ?
FYI: SQL Server 2K with SP3.
Very appreciated for any help.
KNC
This will work if the retention period of the publication is longer than the
age of the backup.
Hilary Cotter
Looking for a SQL Server replication book?
Now available for purchase at:
http://www.nwsu.com/0974973602.html
"KNC" <khanh@.glassegg.com> wrote in message
news:1102943950.567639.151310@.z14g2000cwz.googlegr oups.com...
> hi all,
> We currently encounter a big trouble:
> We have set up a model of synchronization from PDA to SQL Server
> succesfully. Everything is OK until SQL Server database met a trouble
> and needed to restore database. We restored a rather old database (1
> week ago) and then so many erros appeared. Database that is in PDA
> contains much newer data than on SQL Server. When we synchorize, it
> appeared error 28549: "The row update or insert cannot be reapplied due
> to an integrity violation".
> I would like to ask whether there is a standard process for Merge
> Replication in case of restoring old database ?
> FYI: SQL Server 2K with SP3.
> Very appreciated for any help.
> KNC
>
|||hi Hilary,
You seems to misunderstand me, of course it still works. But it will
have trouble in following scenario:
- day 6, set up Merge Replication on SQL Server
- day 8, back up SQL Server database
- day 10, there is 1 new record 001 which is inserted into SQL
Server. Then it was synchronized with PDA, so PDA also contains this
new record 001.
- day 12, SQL Server database is corrupted, we restored from day 8.
Then record 001 is also inserted after database restored. When
synchronizing with PDA, it is conflicted with error 28549.
I would like to ask what is the standard process for Merge in case of
SQL server database is often restored.
Thanks much,
Khanh
Hilary Cotter wrote:
> This will work if the retention period of the publication is longer
than the[vbcol=seagreen]
> age of the backup.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> Now available for purchase at:
> http://www.nwsu.com/0974973602.html
> "KNC" <khanh@.glassegg.com> wrote in message
> news:1102943950.567639.151310@.z14g2000cwz.googlegr oups.com...
trouble[vbcol=seagreen]
(1[vbcol=seagreen]
due[vbcol=seagreen]

Monday, March 26, 2012

Merge Replication w/ Web Synchronization Across Non-Trusted Domain

I have a requirement to replicate a portion of a 2005 database using merge
replication where the database server is in a workgroup at location A and the
web server is in an AD domain at location B. Both locations are connected
via a VPN.
Becuase of the disparate domains we are unable to push snapshots to a share
on the Web Server w/o using FTP. After specifying the FTP information in the
FTP Snapshot and Internet dialog, the following message is returned when
attempting to start the Snapshot Agent:
Message: The replication agent failed to create the directory
'\\172.27.1.187\unc\ftp\DAYMONJPSV02$TEST_CORE_APP RISCORE1\20071218021362\'.
Stack: at
Microsoft.SqlServer.Replication.Utilities.CreateDi rectoryWithExtendedErrorInformation(String directory)
at
Microsoft.SqlServer.Replication.Snapshot.SnapshotP rovider.CreateSnapshotFolders()
at
Microsoft.SqlServer.Replication.Snapshot.MergeSnap shotProvider.CreateSnapshotFolders()
at
Microsoft.SqlServer.Replication.Snapshot.SqlServer SnapshotProvider.GenerateSnapshot()
at Microsoft.SqlServer.Replication.SnapshotGeneration Agent.InternalRun()
at Microsoft.SqlServer.Replication.AgentCore.Run() (Source: MSSQL_REPL,
Error number: MSSQL_REPL52026)
Get help: http://help/MSSQL_REPL52026
Source: mscorlib
Target Site: Void WinIOError(Int32, System.String)
Message: Message: Logon failure: unknown user name or bad password.
Stack: at System.IO.__Error.WinIOError(Int32 errorCode, String
maybeFullPath)
at System.IO.Directory.InternalCreateDirectory(String fullPath, String
path, DirectorySecurity dirSecurity)
at System.IO.Directory.CreateDirectory(String path, DirectorySecurity
directorySecurity)
at
Microsoft.SqlServer.Replication.Utilities.CreateDi rectoryWithExtendedErrorInformation(String directory) (Source: mscorlib, Error number: 0)
The user id and password are those of a domain user for the FTP server at
location B. Do I have to use a non-AD account?
You need to use a snapshot account which has rights to modify to
\\172.27.1.187\unc. You specify this account in sp_addpublication_snapshot
using the @.job_login and @.job_password parameters.
This account should exist on \\172.27.1.187 and your publisher.
http://www.zetainteractive.com - Shift Happens!
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"parchk" <parchk@.discussions.microsoft.com> wrote in message
news:7575E064-365A-49B4-B479-AD3C7D4E14C8@.microsoft.com...
>I have a requirement to replicate a portion of a 2005 database using merge
> replication where the database server is in a workgroup at location A and
> the
> web server is in an AD domain at location B. Both locations are connected
> via a VPN.
> Becuase of the disparate domains we are unable to push snapshots to a
> share
> on the Web Server w/o using FTP. After specifying the FTP information in
> the
> FTP Snapshot and Internet dialog, the following message is returned when
> attempting to start the Snapshot Agent:
> Message: The replication agent failed to create the directory
> '\\172.27.1.187\unc\ftp\DAYMONJPSV02$TEST_CORE_APP RISCORE1\20071218021362\'.
> Stack: at
> Microsoft.SqlServer.Replication.Utilities.CreateDi rectoryWithExtendedErrorInformation(String
> directory)
> at
> Microsoft.SqlServer.Replication.Snapshot.SnapshotP rovider.CreateSnapshotFolders()
> at
> Microsoft.SqlServer.Replication.Snapshot.MergeSnap shotProvider.CreateSnapshotFolders()
> at
> Microsoft.SqlServer.Replication.Snapshot.SqlServer SnapshotProvider.GenerateSnapshot()
> at Microsoft.SqlServer.Replication.SnapshotGeneration Agent.InternalRun()
> at Microsoft.SqlServer.Replication.AgentCore.Run() (Source: MSSQL_REPL,
> Error number: MSSQL_REPL52026)
> Get help: http://help/MSSQL_REPL52026
> Source: mscorlib
> Target Site: Void WinIOError(Int32, System.String)
> Message: Message: Logon failure: unknown user name or bad password.
> Stack: at System.IO.__Error.WinIOError(Int32 errorCode, String
> maybeFullPath)
> at System.IO.Directory.InternalCreateDirectory(String fullPath, String
> path, DirectorySecurity dirSecurity)
> at System.IO.Directory.CreateDirectory(String path, DirectorySecurity
> directorySecurity)
> at
> Microsoft.SqlServer.Replication.Utilities.CreateDi rectoryWithExtendedErrorInformation(String
> directory) (Source: mscorlib, Error number: 0)
> The user id and password are those of a domain user for the FTP server at
> location B. Do I have to use a non-AD account?
|||Thanks Hillary. I am assuming that becasue the servers are in two different
security domains that the account should be local on both servers? Also, if
the publication has already been created, can it be modified to modify the
job_login and job_password parameters? Thanks in advance.
"Hilary Cotter" wrote:

> You need to use a snapshot account which has rights to modify to
> \\172.27.1.187\unc. You specify this account in sp_addpublication_snapshot
> using the @.job_login and @.job_password parameters.
> This account should exist on \\172.27.1.187 and your publisher.
> --
> http://www.zetainteractive.com - Shift Happens!
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "parchk" <parchk@.discussions.microsoft.com> wrote in message
> news:7575E064-365A-49B4-B479-AD3C7D4E14C8@.microsoft.com...
>
>
|||Exactly, it should be a local account on both servers.
You can modify the snapshot account by right clicking on the publication in
SSMS, selecting properties and clicking on the agent security tab.
http://www.zetainteractive.com - Shift Happens!
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"parchk" <parchk@.discussions.microsoft.com> wrote in message
news:915C3515-3E0A-4755-88B7-DE72D927A0E2@.microsoft.com...[vbcol=seagreen]
> Thanks Hillary. I am assuming that becasue the servers are in two
> different
> security domains that the account should be local on both servers? Also,
> if
> the publication has already been created, can it be modified to modify the
> job_login and job_password parameters? Thanks in advance.
> "Hilary Cotter" wrote:

Merge Replication Synchronization Manager

Hi,
after upgrading a client within a Merger Replication scenario from MSDE2000A
to SQL Express SP1 the subscription is no longer listed within the
synchronisation manager.
How to register the subscription within Synchronization Manager?
(I know it is possible within Management Studio but I need to automate this
process).
Thanks in advance,
Thomas
have you tried to pull it again in WSM?
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"ThoHot00" <ThoHot00@.discussions.microsoft.com> wrote in message
news:F36273CF-38BA-4A7C-A373-CB96CCDE37E4@.microsoft.com...
> Hi,
> after upgrading a client within a Merger Replication scenario from
> MSDE2000A
> to SQL Express SP1 the subscription is no longer listed within the
> synchronisation manager.
> How to register the subscription within Synchronization Manager?
> (I know it is possible within Management Studio but I need to automate
> this
> process).
> Thanks in advance,
> Thomas
|||Hi Hilary,
I haven't tried to pull it again within WSM. I would need to reregister it
within WSM, but since this upgrade occurs within a software upgrade I do not
have access to all client machines and I need a solution that I can integrate
into an installer package.
The subscription registration can still be found under
HKLM\Software\Microsoft\Microsoft SQL Server\80\Replication\Subscriptions\...
If I copy this entry to HKLM\Software\Microsoft\Microsoft SQL
Server\90\Replication\Subscriptions\... the subscription shows up in WSM and
works fine. I'm a little bit worried about the fact that within this key is
entry called subid. When I regenerate this entry using "Management Studio"
the subid is different and there is one additional entry called WebSync.
WebSync is always 0 in our case but I don't have a clue where the changed
subid comes from. If I call sp_helpmergepullsubscription it still shows the
"old" subid.
Greetings,
Thomas
"Hilary Cotter" wrote:

> have you tried to pull it again in WSM?
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "ThoHot00" <ThoHot00@.discussions.microsoft.com> wrote in message
> news:F36273CF-38BA-4A7C-A373-CB96CCDE37E4@.microsoft.com...
>
>

Friday, March 23, 2012

Merge Replication Synchronization Issue

Hello,
I have a merge replication problem has been driving me nuts for the last couple of days and I haven't been able to find any information on it from other posts in this group. The problem is that extra uploads (as UPDATEs) are being sent to the publisher w
hen the subscriber sync's.
First off our setup info:
Server:
- SQL Server 2000 Enterprise (SP3).
- Running on a clustered Win 2000 server (Active/Passive).
- Publisher and Distributor are located on the same virtual Sql Server instance.
- Merge publication using dynamic horizontal data filters with join filters off of filtered tables.
- Dynamic snapshots used for each subscribers data initialization.
Client: MSDE (SP3)
- Running Win XP Tablet Edition.
- Anonymous on demand subscription.
Table Info:
Primary Table: Retailers (PK ApplicationNumber char(7))
Sub Table: RetailerInformation (PK ApplicationNumber char(7), which is also a FK to Retailers.ApplicationNumber)
Replication Info Table: ReplicationRetailers (PK ApplicationNumber char(7), UserLogin varchar(20) (This is the windows login returned by the SUSER_SNAME() function during the filtering during the sync))
Publication Info:
ReplicationRetailers table has a dynamic filter of 'WHERE UserLogin = SUSER_SNAME()'
ReplicationRetailers Join Filters Retailers on ApplicationNumber
Retailers Join Filters RetailerInformation on ApplicationNumber
Our replication is working great; the correct data is being sent down to the subscribers database, speeds are excellent, etc... However we noticed a strange behavior while testing yesterday. If I assign a new retailer to a user (by adding a row to the Re
plicationRetailers table) the first sync down to the subscription works fine; all the applicable Retailer records are INSERTed into the subscriber. However, when the subscriber sync's again, an almost identical number of UPDATEs are sent back up to the s
erver. The number of UPDATEs never quite equals the number of INSERTs but is usually 2-4 less. The data that gets UPDATEd up to the publisher is not different from the data that was INSERTed to the subscriber and I know that there are no subscriber tabl
e triggers firing that update any data.
I've traced the merge process to see what tables are sending data back up to the publisher and confirmed that it is the Retailers table and its associated sub table that sends the updates. However I cannot tell exactly which records are being sent.
I know this is not the normal behavior during a sync as I have other tables that have an identical table filter that only send data when there are changes (in the same publication). So I guess I have a couple questions:
1) Has anyone else seen this behavior?
2) Is so, what did you do to fix it?
3) Is there some way to use the MSmerge_contents and MSmerge_genhistory tables to figure out what rows are going to be sent durning the next sync BEFORE the sync occurs?
Thank you very much for your help.
Wesley Brown
Each row in a merge published table has a GUID column which is used to uniquely identify each row.
Each row in MSmerge_contents corresponds to changes which have happened locally on the database.
Each row in MSmerge_contents will contain an generation number.
When the merge agent runs compares the generation numbers in in MSmerge_contents and the msmerge_replinfo table between the publisher and subscriebr to determine which GUID's have incremented their generation number.
Then depending on whether the publisher or subscriber has the higher generation number a stored procedure is constructed with parameters based on the values in either the publisher or subscriber published tables and executed on the subscriber or publisher
|||Thanks for the response Hilary.
I've used the information you gave me and created a query to show me the state of the subscriber and the publisher after
the 1st sync. Interestingly I noticed that there are no rows in the publishers MSmerge_contents table for some of the
replicated data. I think the problem relates to the fact that most of the records in our database have never been
replicated (which makes sense given that we are using filters and have only been testing with a couple user logins). When
a database is turned into a publisher none of the existing rows are added to the MSmerge_contents table. When the sync
occurs the data gets added to the subscribers MSmerge_contents table but NOT the publishers MSmerge_contents table. I
think this may be a bug as all the required information is known when this sync is being performed. When the next Sync is
started the publisher correctly determines that the subscriber has new rows that it needs to upload for the
MSmerge_contents table. As for why the inserts to the publisher show up as updates I’m not sure; it could be that the
publisher adds the rows itself at the start of the 2nd sync and then checks the values it has for the rowguid column against
those in the subscriber database, however I’m really not sure.
Does anyone know if this behavior (the lazy load into the MSmerge_contents table) is by design?
sql

Merge Replication Questions [SQL2k5 non express]

I can choose synchronization direction for articles: a) Bidirectional b) one way

1) Is that possible somehow to replicate the schema only of an article but no synchronization / zero direction :-)/

2) Same question about columns, I should replicate schema only for few columns, but without data synch. These columns are freely updateable at anywhere (publisher and subscribers), but the data changes shouldn't be replicated.

Thanks for the answers in advance

I guess that you want to keep same schema's at two or more machines?

I do not know whether you can do it using replication, actually I think that there is no way to do something like that.

What I would do is that I would script database, and make same copies at all locations. Later when you need some updates/changes to schema, you can script those also. Not only that, but you can build your own schema replication system, so everything could go, kind of, semi-automatic.

|||

Sorry, my initial question was not clear.

I would like to replicate all tables in the db, except 1-2 tables and 3-4 columns only.

Let's see the following example:

There are about 30 tables to replicate let's name those T1, T2, T3, ... T30 and the column names are T1C1, T1C2, ... T2C1, T2C2, .... etc

I would like to replicate all tables, except T15 and T16 tables (all columns) and 4 columns T8C4, T8C5, T9C2 and T9C3. But the schema should be the same at all places, so T15 and T16 should be exist at subscribers and publishers and the mentioned columns also, but data should not be replicated to-from that 2 table and from/to that 4 columns.

|||

Now it is much clearer to me.

As I said, you can copy your schema to be same on all databases, but you can filter out your publication so you just replicate tables T1-T14 and T17-T30, and to replicate all columns except T8C4, T8C5, T9C2 and T9C3.

If you then choose to initialize, you will loose tables/columns that are not in replication, but you can add them later.

Or you can make publication, then copy db schema using script to subscriber (so you have rowguid) and choose do not initialize.

Test it, play around with it. Make on your own sql server two tiny db's with two tables (one publisher and one subscriber) and play with it.

|||

THis can be done with replication. What you do is create a publication containing all the tables and columns you want. You can then script out table T15 and T16, put it in a file, and reference it in parameter @.post_snapshot_script for stored procedure sp_addpublication or sp_addmergepublication.

|||

Thanks for the answer. It took a bit longer, because I ran into a little problem, I got the following error message on one of my stored procedure in post-snapshot script:

"The query processor could not produce a query plan. For more information, contact Customer Support Services."

It was because i forgot to include the:

set QUOTED_IDENTIFIER ON

maybe this is a bug of sql2k5 SP1

btw, I moved the T8C4, T8C5, T9C2 and T9C3 columns to separate tables as well, and there are foreign keys pointing back to the original tables PKs

Thanks again for the solution.

Friday, March 9, 2012

Merge Replication error while applying Snapshot

Hi,

i am getting the below error while applying running the Synchronization agent for the Subscriber. I have created replication topology with one central server and one subscriber. Here central server has windows server 2003 and subscriber has windows XP. Both are having SQL server 2005. After creating the merge subscriber, i am runnnig the Synchronization agent manually for the first time. While running that i am getting below error. Anybody aware of this error.

2006-06-24 00:26:00.175 Applying the snapshot to the Subscriber
2006-06-24 00:26:02.722 The schema script 'D_NUM_7.sch' could not be propagated to the subscriber.
2006-06-24 00:26:02.784 Category:NULL
Source: Merge Replication Provider
Number: -2147201001
Message: The schema script 'D_NUM_7.sch' could not be propagated to the subscriber.
2006-06-24 00:26:02.816 Category:AGENT
Source: WMBT-07
Number: 0
Message: The process could not read file '\\WMBT-01\repldata\unc\LTR-IN001_TEST_PUB\20060624034804\D_NUM_7.sch' due to OS error 1265.
2006-06-24 00:26:02.831 Category:OS
Source:
Number: 1265
Message: The system detected a possible attempt to compromise security. Please ensure that you can contact the server that authenticated you.

does the account under which the agent is running under have access to the share?|||

Greg,

Thanks for giving me the response...

Actually i am not clear about the Account... How to see the Account under which Agent is running?

I still dont understand where we are linking the Account and Agent.

Can you help on this ?

Thanks in advance.

|||

Greg,

Are you asking the about Agent in Central Server or in the Subscriber.

Thanks.

|||When you setup replication, you are asked to specify security credentials for the Snapshot agent, Log Reader Agent, Distribution Agent, Merge Agent, Queued Reader Agent. (Which agents you need to specify credentials for vary based on the method of replication.) The account that you specified for either the distribution agent (for snapshot or transactional replication) or the merge agent (for merge replication) needs to have the authority to access the snapshot folder in order for this to work successfully.|||

There are two places you may need to check.

1. Since snapshot files are saved under distributor, in your case, it may be the central server, which is both publisher and distributor, so make sure your publication snapshot files are saved under an alternate folder, UNC folder, which can be accessed by merge agent running on the subscriber.

2. Check merge agent account which is used to connect to distributor, it must have read permissions on the snapshot share. You can check it through open merge agent job properties.

Hope the above will be helpful.

Thanks

Yunjing

|||

Hi All,

Thanks for all you replies. I solved the problem i faced.

Normally when i create a Subscriber for Account under which Merge Agent will run i used to give as "Run Under SQL Server Agent Service Account" . It was working for me all these days. In all the machines where I created Replication was having windows XP. But when i was trying to create the Replication with systems with windows Server 2003, i have got the above said error.

To solve that error i have created one windows account in the Publisher and Subscriber with same name and same password. Then while creating the Publisher and Subscriber I was using this windows account as process Account for all the Agents. After that it was working fine. Here the windows account has to be there is both Publisher and Subscriber with same name and same Password. It was working for me. I have added that windows account as part of Administrator Group.

Thanks,

Thams.

Merge Replication error while applying Snapshot

Hi,

i am getting the below error while applying running the Synchronization agent for the Subscriber. I have created replication topology with one central server and one subscriber. Here central server has windows server 2003 and subscriber has windows XP. Both are having SQL server 2005. After creating the merge subscriber, i am runnnig the Synchronization agent manually for the first time. While running that i am getting below error. Anybody aware of this error.

2006-06-24 00:26:00.175 Applying the snapshot to the Subscriber
2006-06-24 00:26:02.722 The schema script 'D_NUM_7.sch' could not be propagated to the subscriber.
2006-06-24 00:26:02.784 Category:NULL
Source: Merge Replication Provider
Number: -2147201001
Message: The schema script 'D_NUM_7.sch' could not be propagated to the subscriber.
2006-06-24 00:26:02.816 Category:AGENT
Source: WMBT-07
Number: 0
Message: The process could not read file '\\WMBT-01\repldata\unc\LTR-IN001_TEST_PUB\20060624034804\D_NUM_7.sch' due to OS error 1265.
2006-06-24 00:26:02.831 Category:OS
Source:
Number: 1265
Message: The system detected a possible attempt to compromise security. Please ensure that you can contact the server that authenticated you.

does the account under which the agent is running under have access to the share?|||

Greg,

Thanks for giving me the response...

Actually i am not clear about the Account... How to see the Account under which Agent is running?

I still dont understand where we are linking the Account and Agent.

Can you help on this ?

Thanks in advance.

|||

Greg,

Are you asking the about Agent in Central Server or in the Subscriber.

Thanks.

|||When you setup replication, you are asked to specify security credentials for the Snapshot agent, Log Reader Agent, Distribution Agent, Merge Agent, Queued Reader Agent. (Which agents you need to specify credentials for vary based on the method of replication.) The account that you specified for either the distribution agent (for snapshot or transactional replication) or the merge agent (for merge replication) needs to have the authority to access the snapshot folder in order for this to work successfully.|||

There are two places you may need to check.

1. Since snapshot files are saved under distributor, in your case, it may be the central server, which is both publisher and distributor, so make sure your publication snapshot files are saved under an alternate folder, UNC folder, which can be accessed by merge agent running on the subscriber.

2. Check merge agent account which is used to connect to distributor, it must have read permissions on the snapshot share. You can check it through open merge agent job properties.

Hope the above will be helpful.

Thanks

Yunjing

|||

Hi All,

Thanks for all you replies. I solved the problem i faced.

Normally when i create a Subscriber for Account under which Merge Agent will run i used to give as "Run Under SQL Server Agent Service Account" . It was working for me all these days. In all the machines where I created Replication was having windows XP. But when i was trying to create the Replication with systems with windows Server 2003, i have got the above said error.

To solve that error i have created one windows account in the Publisher and Subscriber with same name and same password. Then while creating the Publisher and Subscriber I was using this windows account as process Account for all the Agents. After that it was working fine. Here the windows account has to be there is both Publisher and Subscriber with same name and same Password. It was working for me. I have added that windows account as part of Administrator Group.

Thanks,

Thams.

Saturday, February 25, 2012

Merge replication and synchronization

Hi!
i have big problem, i had to remove my merge replication (between Sql2000
MSDE, one way replication only from Publisher to Subsciber). After
recreating this replication, merge agent do not wan't to merge any data, i'm
obtaining NO DATA NEED TO BE MERGED.
i can update all values (by SQL Updatte) in replication tables and merge
will see this data, but what about deletes?
my question is, is it possible to make FULL synchronization between
subscriber and publicator?
thanks
Kuba
It sure is. Let me see if I understand you. You had a working publication
subscriber. You removed the publication. You recreated it, and now the data
does not flow from the publisher to the subscriber, or only updates flow?
How did you recreate the subscriber? At this point it is probably best if
you drop the publication and recreate it, and redeploy the snapshot. Do not
use the no sync option.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
"Kuba" <k.gluszkiewicz@.citysoftware.com.pl> wrote in message
news:u%23YxQFymEHA.1904@.TK2MSFTNGP09.phx.gbl...
> Hi!
> i have big problem, i had to remove my merge replication (between Sql2000
> MSDE, one way replication only from Publisher to Subsciber). After
> recreating this replication, merge agent do not wan't to merge any data,
i'm
> obtaining NO DATA NEED TO BE MERGED.
> i can update all values (by SQL Updatte) in replication tables and merge
> will see this data, but what about deletes?
> my question is, is it possible to make FULL synchronization between
> subscriber and publicator?
> thanks
> Kuba
>
|||Hi Hilary!
i had a merge replication which works fine
someday i had to remove this replication, i removed subscibers (after that i
used on subscribers sp_mergesubscription_cleanup stored procdure) and next
i removed publication.
after that user whose working on publication machine made a lot of data
changes
after few days i created replication process again (publisher and
subscibers),
now merge agent do not see which records was deleted in publisher database
when my replication was removed, my subscribers inlcudes too many records,
which should be deleted
sorry Hilary for my english, i tried to explain it clearly, i hope you will
understand me
tanks in advance
Kuba
Uytkownik "Hilary Cotter" <hilary.cotter@.gmail.com> napisa w wiadomoci
news:%23nMEWt%23mEHA.3820@.TK2MSFTNGP09.phx.gbl...
> It sure is. Let me see if I understand you. You had a working publication
> subscriber. You removed the publication. You recreated it, and now the
data
> does not flow from the publisher to the subscriber, or only updates flow?
> How did you recreate the subscriber? At this point it is probably best if
> you drop the publication and recreate it, and redeploy the snapshot. Do
not[vbcol=seagreen]
> use the no sync option.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> "Kuba" <k.gluszkiewicz@.citysoftware.com.pl> wrote in message
> news:u%23YxQFymEHA.1904@.TK2MSFTNGP09.phx.gbl...
Sql2000
> i'm
>
|||Sounds like you didn't re-apply the snapshot at the subscriber...
"Kuba" wrote:

> Hi Hilary!
> i had a merge replication which works fine
> someday i had to remove this replication, i removed subscibers (after that i
> used on subscribers sp_mergesubscription_cleanup stored procdure) and next
> i removed publication.
> after that user whose working on publication machine made a lot of data
> changes
> after few days i created replication process again (publisher and
> subscibers),
> now merge agent do not see which records was deleted in publisher database
> when my replication was removed, my subscribers inlcudes too many records,
> which should be deleted
> sorry Hilary for my english, i tried to explain it clearly, i hope you will
> understand me
> tanks in advance
> Kuba
> U?ytkownik "Hilary Cotter" <hilary.cotter@.gmail.com> napisa3 w wiadomo?ci
> news:%23nMEWt%23mEHA.3820@.TK2MSFTNGP09.phx.gbl...
> data
> not
> Sql2000
>
>
|||dzien dobry.
Your English is better than my Polish
Right click on your merge publication and select view conflicts. This may
explain why some of your data is inconsistent.
I'm still unsure if you did a no sync subscription (the subscriber already
has the schema and data) or not. If you did a no sync, the best way to get
everything in a consistent state is to redeploy your subscription again. If
you did not do a no sync, right click on your publication and reinitialize.
Then start up your snapshot agent, and when it shuts itself down, start up
your merge agent.
if you did a no sync, you should drop your subscription and then either
1) backup your publication database and restore it on your subsciber and
then do another no sync subscription or
2) do a sync subscription (the subscriber does not have the schema and
data).
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
"Kuba" <k.gluszkiewicz@.citysoftware.com.pl> wrote in message
news:O9P1Uc$mEHA.3896@.TK2MSFTNGP15.phx.gbl...
> Hi Hilary!
> i had a merge replication which works fine
> someday i had to remove this replication, i removed subscibers (after that
i
> used on subscribers sp_mergesubscription_cleanup stored procdure) and
next
> i removed publication.
> after that user whose working on publication machine made a lot of data
> changes
> after few days i created replication process again (publisher and
> subscibers),
> now merge agent do not see which records was deleted in publisher database
> when my replication was removed, my subscribers inlcudes too many records,
> which should be deleted
> sorry Hilary for my english, i tried to explain it clearly, i hope you
will[vbcol=seagreen]
> understand me
> tanks in advance
> Kuba
> Uytkownik "Hilary Cotter" <hilary.cotter@.gmail.com> napisa w wiadomoci
> news:%23nMEWt%23mEHA.3820@.TK2MSFTNGP09.phx.gbl...
publication[vbcol=seagreen]
> data
flow?[vbcol=seagreen]
if[vbcol=seagreen]
> not
> Sql2000
data,[vbcol=seagreen]
merge
>

Monday, February 20, 2012

Merge Replication and MSDE

I suppose it depends on what you want to do as a result
of the synchronization finishing. The easiest way to make
the process event-driven is to add an additional step to
the merge agent's job and modify the other steps to
always culminate in the execution of your new step. This
additional step could execute a SP, or run a command,
whatever you have in mind.
The alternatives are is to query the history tables (eg
MSdistribution_history), or
tempdb.dbo.MSreplication_agent_status or run the
penultimate script on
http://www.replicationanswers.com/OtherSQL.htm. These 3
solutions each are essentially polling methods and you
might end up doing a lot of unnecessary server work that
way.
Rgds,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)

>--Original Message--
>I hava a scenario where I have an SQL Server set up as
the publisher (merge)
>and the subscribers are Laptops with MSDE which work
mostly offline.
>The subscribers are updated once they are online with
the publisher.
>My question is: How can the subscriber tell if the MSDN
database has
>finished the replication with the publisher?
>You see some times the laptops are online just a few
minutes and the
>connection is slow. I need to make sure the subscribers
are online just long
>enough to complete the merge !
>I appreciate any help I get can on this issue :-)
>Regards
>Peter
>.
>
You see I want to make sure the the Subscribers are online long enough to
finish the merge replication.
Is it possible to Start the merge replication using a Stored Procedure
etc... ? That way the users can initiate the merge replication themselves.
By the way, MS Access 2003 is used as a front end to the MSDE database, so
inisiating a merge replication would preferably be started from Access (and
hopefully the user would get some indication that the merge replication was
completed)
ragards
Peter
"Paul Ibison" wrote:

> I suppose it depends on what you want to do as a result
> of the synchronization finishing. The easiest way to make
> the process event-driven is to add an additional step to
> the merge agent's job and modify the other steps to
> always culminate in the execution of your new step. This
> additional step could execute a SP, or run a command,
> whatever you have in mind.
> The alternatives are is to query the history tables (eg
> MSdistribution_history), or
> tempdb.dbo.MSreplication_agent_status or run the
> penultimate script on
> http://www.replicationanswers.com/OtherSQL.htm. These 3
> solutions each are essentially polling methods and you
> might end up doing a lot of unnecessary server work that
> way.
> Rgds,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
> (recommended sql server 2000 replication book:
> http://www.nwsu.com/0974973602p.html)
>
> the publisher (merge)
> mostly offline.
> the publisher.
> database has
> minutes and the
> are online just long
>
|||To kick off the merge agent using stored procedures, you
can use sp_start_job. There are other programattic
options, usually involving ActiveX controls or command-
line execution, but the above system stored procedure
should do.
Rgds,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
|||Can you give me an example on how a sp_start_job would typically look like to
start the merge replication.
Another question: There are several subscribers. Is it one merge agent for
each subscriber ?
regards
Peter
"Paul Ibison" wrote:

> To kick off the merge agent using stored procedures, you
> can use sp_start_job. There are other programattic
> options, usually involving ActiveX controls or command-
> line execution, but the above system stored procedure
> should do.
> Rgds,
> Paul Ibison SQL Server MVP, www.replicationanswers.com
> (recommended sql server 2000 replication book:
> http://www.nwsu.com/0974973602p.html)
>
|||exec msdb..sp_start_job 'DH1791628-xxxPublisher-
xxxPublisher-DH1791628-3'
One merge agent per subscriber - yes.
Rgds,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
|||I use SQLDMO to start the Merge Agent in my VB application
I can then check the status of the Job to determine when it has completed.
-Mike
"Peter" <Peter@.discussions.microsoft.com> wrote in message
news:55FC83AF-6BE4-4439-9CC4-B73DB0506385@.microsoft.com...
> You see I want to make sure the the Subscribers are online long enough to
> finish the merge replication.
> Is it possible to Start the merge replication using a Stored Procedure
> etc... ? That way the users can initiate the merge replication
themselves.
> By the way, MS Access 2003 is used as a front end to the MSDE database, so
> inisiating a merge replication would preferably be started from Access
(and
> hopefully the user would get some indication that the merge replication
was[vbcol=seagreen]
> completed)
> ragards
> Peter
> "Paul Ibison" wrote: