Are you the publisher? Claim or contact us about this channel

Embed this content in your HTML


Report adult content:

click to rate:

Account: (login)

More Channels


Channel Catalog

Channel Description:

Discussions on SQL Server Replication

older | 1 | .... | 157 | 158 | (Page 159) | 160 | 161 | .... | 181 | newer

    0 0

    I am working on a replication issue where the distribution database has been set to point to the Publisher database. I am attempting to remove all replication and start again.

    I have run sp_dropdistpublisher on all the publishers that refer to the database as the distributor, but if I run

    exec sp_replicationdboption @dbname = N'xxxx', @optname = N'publish', @value = N'true'
    (where xxxx is the name of the publisher database that has also been configured for distribution)

    then it fails with:

    Msg 20028, Level 16, State 1, Procedure sp_MSpublishdb, Line 56
    The Distributor has not been installed correctly. Could not enable database for publishing.

    If I generate the drop commands for all replication objects these involve running sp_dropdistributiondb, however this would attempt to drop the database. I don't want to do this - I just want to (ideally) remove all distribution objects from it and 'unmark' it as a distribution database.

    This is a production environment, so I need to tread with care!

    Any help appreciated.

    0 0


    Everything is in the title, if I run a select count(1) from table, I get a result of 0 rows. If I do a select * from table it takes forever to read and finish the query. Also disk is reading the DB files at speed of 330 MB/sec while doing that query.

    So.... WTF ? Any one got an idea on how I fix that ?



    a 115 GB of data for 0 rows................. wtf :)

    TableName SchemaName RowCounts TotalSpaceKB UsedSpaceKB UnusedSpaceKB
    msg dbo 0 115713984 115697280 16704


    Edit 2: truncate would be nice but the table is replicated ... hahaha

    0 0


    I am tasked to replicate an SQL Server database to a different machine. From SQL Server 2005 (Win Server 2003) to SQL Server 2012 (Win Server 2012).

    From the server I saw there is a *.bak file being generated daily as a backup, is *.bak an Online backup? But I am thinking to perform an offline copy of *.mdf and *.ldf files.

    I would like to know what is the difference if I were to:

    1) "Restore" the DB using the .bak file?

    2) "Attach" the DB using .mdf and .ldf file?

    Which is the "better/correct" way to replicate the DB, without data lost?

    Thanks in advanced!

    0 0

    Could anyone help explain the below as it's been on my mind for some time.

    When we add a new article to a publication what is the difference in running the snapshot agent in replication monitor to kick start a new snapshot to deliver all tables v.s. why/when would you right click a publication and 'Reinitialize All Subscriptions' then right click the snapshot agent and run it?  Is it all down to the snapshot retention/expiration date set?  If so I can't say I've ever had an issue with not doing a full reinitialize.

    0 0


    I want to get all of information about replication for example is push or pull , is transactional or merg ... , and others.


    0 0

    I have a publication of 4 tables, two of which are huge.

    I can't seem to get the Snapshot agent to break up its work 

    I have tried Native and database snapshot Sync Methods and manually added a -MaxBCPThreads 12 parameter to the SQL Agent Job. The defaults for the Snapshot(1) and Distribution(4) agent profiles have been set to 10.

    I don't know what else to do.   Because I am replicating to Azure I need the distribution to be multi-threaded in order for the Snapshot to be applied in a reasonable amount of time over multiple WAN threads.

    How do I get SQL Server to cooperate here?



    0 0

    I'm reading that Replication has been deprecated and will be removed in future versions. 

    We are setting up a new Data Warehouse on 2016 and were planning to use replication, however we don't want to go through all the work to setup Replication if it will be removed in the next version.

    0 0

    We have merge replication config between two servers, we scheduled merge agent to run for every 1 minute. merge agent taking 20 mins to merge the changes and even there are no changes its taking 18 mins. how to troubleshoot this issue?

    Thanks in advance.

    0 0
  • 06/27/16--09:39: Transactional Replication
  • Hello All,

    We had a weekend maintenance for Transactional replication where we tried to move 800Gb of data from sql 2012 to sql 2008, Where i broke down the publications in to three sets, One of the publication has a table with 53Millions row counts on top of it we had the indexes also, data got moved fast but the index operation is taking long time , I have verified the wait stats on the server looks like i have all the CXPacket waits but verified the MaxDOP Option too 

    Memory : 45Gb

    CPU : 8 processors

    Any suggestions please?




    0 0


    I'm fairly new to MSSQL, but I was wondering...

    I want 2 nodes

    One in location A, one in Location B (about 9 miles apart over a 20Mb pipe).

    Can I set up a cluster between them? Do they have to have shared storage or does MSSQL have a way to mirror/replicate over?

    If anyone else has a similar setup I would greatly appreciate your advise.

    0 0
  • 07/02/16--22:39: Log Shipping
  • I have configured log shipping as replication ,after few days it got error out on primary backup of transaction log was not happening then I took full backup after transactional log backup  was happening on  primary, but still copy and restore is failing on secondary, its saying but error message ,

    The process could not be created for step 1 of job 0x49157E5B17C28348B372DA08BB1A7F99 (reason: The system cannot find the file specified).  The step failed.

    0 0

    Hello everyone

    We have setup merge replication: Distributor/Publisher are on the same Server with Sql Server 2012 RTM (11.0.2100). Subscribers are on notebook with Sql Server 2012 Express SP2 (11.0.5058).

    Time to time, user reports that synchronisation fails with the following error:

    The merge process failed because it detected a mismatch between the replication metadata of the two replicas, such that some changes could be lost leading to non-convergence. This could be due to the subscriber not having synchronized within the retention period, or because of one of the replicas being restored to a backup older than retention period, or because of the publisher performing more aggressive cleanup on articles of type download-only and articles with partition_options = 3. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147199363) Get help: http://help/MSSQL_REPL-2147199363

    Le filigrane de création commune n'est pas valide dans ce réplica, parce qu'il n'existe pas ou que les métadonnées relatives aux modifications qui n'ont pas encore été propagées ont peut-être été nettoyées. (Source: MSSQLServer, Error number: 21800) Get help: http://help/21800

    Untill recently we always thought the reason of the failure was the first one. (User didn't synchronize during the retention period). So everytime invalid subscription were reset on both side (notebook and server) with upload_first = 'false'. Sometimes It was not enougth and the only solution was to drop the subscription and recreate it on the notebook.

    But now we facing the same problem with a new notebook installed for a less than a month (although subscription expiration périod is set for 90 days). 

    We checked Database on server: Upload_options is set to 0 on sysmergearticles for every article and partition_options is set 0 on sysmergepartitioninfo. Database server were never restored and notebook was installed recently (less than a month)

    So none of the three reasons provided by the error message seems to suits.

    Does anyone have a clue on why this happen ?

    Thank you very much

    0 0

    Hi All,

    I have configured the Replication in SQL Server 2008 R2 among 3 instances. Let's say INSTANCE1 as Publisher, INSTANCE2 as Distributor and INSTANCE3 as Subscriber. All the three instances are in separate VM's. Unfortunately the Hard Disk got corrupted which caused the INSTANCE2 to be down. Later it was decommissioned. 

    We had lost the Distributor Database. So we tried the delete the Publication and Subscription and to reconfigure it. And while deleting, the distributor information's which are available in the INSTANCE1 are not deleted. It throws the following error while disabling the publication and distribution wizard:

    An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
    Named Pipes Provider: Could not open a connection to SQL Server [53].
    Changed database context to 'MyDatabase '.
    OLE DB provider "SQLNCLI10" for linked server "repl_distributor" returned message "Login timeout expired".
    OLE DB provider "SQLNCLI10" for linked server "repl_distributor" returned message "A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online.". (Microsoft SQL Server, Error: 53)
    Is there is any way to delete all and to reconfigure it again from the start?

    Vinesh Senthilvel

    0 0
  • 07/04/16--06:28: my subscriptions cannot sync
  • hi

    I recently created replication and some of subscriptions are in error state and when i want to sync :

    TITLE: View Synchronization Status

    The agent could not be started.

    For help, click:


    An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)


    SQLServerAgent Error: Request to run job C******-*****ting(from User ***\r*****) refused because the job is already running from a request by Start Sequence 0.
    Changed database context to '*****'. (Microsoft SQL Server, Error: 22022)

    For help, click:

    0 0

    Dear experts,

    Let's assume I have 3 different SQL Server instances set up to participate in transactional  replication, Instance A will be a subscriber to instance B and C (B and C are the publishers). If transactional replication are set up as Pull subscription does it mean there will be 3 replication agents running on Instance A?

    Also, to avoid conflict in primary keys I am evaluating the use of GUIDs with the Uniqueidentifiers data type...those anyone has experience in using this fields within transactional replication or what are the options to avoid primary key conflict in transactional replication.


    0 0

    Dear Expert,

    I am looking for an effective approach for disaster recovery transactional replication for the given scenario below

    We have 3 separate geographical sites (site 1(Publisher), site 2(subscriber) and site 3 (subscriber))connected via a WAN Link with One publisher and 2 subscribers.

    Let's assume there is a storage issue on the Publisher (SAN busted), after getting back the SAN online and reconfigured the transactional replication set up on site 2 subscriber, but not able to reconfigure transactional replication on Site 3 because the network connectivity between site 1 and site 3 is down. Now the subscriber on site 2 has received new data in from the publisher, My question is, is site 3 able to catch up on the existing data from the publisher after getting back network access to site 3 or a faster method would be to do a back up and restore of the database from the publisher to site 3 to that it can in sync?

    Also, the size of the database in is Terabytes.

    0 0


    we have 2 sql server 2012 (one sp1 and another sp2) in bidirectional replication with loopback detection enabled. We have used server names (configured in Alias) for the subscriptions. Every replicated table has different identity range to avoid conflicts.

    It works fine most of the time but randomly on the server with less activity the loopback detection fails and the server tries to replicate back the transactions and obviously causing some conflicts. This doesn't happens consistently but we have noticed that the last time happened after network issues (replication warnings tcp semaphore timeout).

    On the distribution database where the issue happens i can see that suddenly the replicated commands doesn't have an originator and after some time it reappears but in the meantime the transactions without originator already caused some conflicts

    0 0


    I need a sample SQL query or script to change the article properties in SQL server transnational replication tables.

    I have attached the sample page for reference where the changes need to be done.

    Could you please help me with the query ?


    Vinodh Selvaraj

    0 0

    I ran a huge delete statement and replication went into critical mode... When I tried to restart the logreader I got the following message

    The process could not execute 'sp_MSadd_replcmds' on 'dbname'

    HELP!!! There is plenty of room on the disk... I have even tried to reinitialize the subscription, but still get the same message...

    0 0

    Hi Team,

    We got request to configure central subscription from 7 publishers with same columns. We tried different ways with out using the sanpshot and initialize from backup. Nothing helped.

    Please guide me how can i create the replication.

    Thanks in Advance for your time and efforts,


older | 1 | .... | 157 | 158 | (Page 159) | 160 | 161 | .... | 181 | newer