Quantcast
Channel: SQL Server Replication forum
Viewing all 4054 articles
Browse latest View live

Merge replication fails with a network error

$
0
0

We have a nightly job that executes a procedure that updates the local SQL database via MERGE with data from our Azure SQL database. Occasionally that job will fail with the following error message:

NT SERVICE\SQLSERVERAGENT. Cannot fetch a row from OLE DB provider "MSDASQL" for linked server "SQLProduction". [SQLSTATE 42000] (Error 7330)  OLE DB provider "MSDASQL" for linked server "SQLProduction" returned message "[Microsoft][ODBC SQL Server Driver][DBNETLIB]General network error. Check your network documentation.". [SQLSTATE 01000] (Error 7412)  OLE DB provider "MSDASQL" for linked server "SQLProduction" returned message"[Microsoft][ODBC SQL Server Driver][DBNETLIB]ConnectionRead (InvalidParam()).". [SQLSTATE 01000] (Error 7412)  OLE DB provider "MSDASQL" for linked server "SQLProduction" returned message "[Microsoft][ODBC SQL Server Driver][DBNETLIB]General network error. Check your network documentation.". [SQLSTATE 01000] (Error 7412)  OLE DB provider "MSDASQL" for linked server "SQLProduction" returned message "[Microsoft][ODBC SQL Server Driver][DBNETLIB]ConnectionRead (recv()).". [SQLSTATE 01000] (Error 7412)  OLE DB provider "MSDASQL" for linked server "SQLProduction" returned message "[Microsoft][ODBC SQL Server Driver]Error in row". [SQLSTATE 01000] (Error 7412)Unable to open Step output file.  The step failed.

I believe this is caused by a network hiccup but I do not have access to the network or firewall that the Azure SQL database is behind. Where should I go from here to troubleshoot this possible connectivity issue?


Distributor Subsystem: Cannot continue the execution because the session is in the kill state.

$
0
0

I have Transactional replication in one environment, I disabled  and configuring it again, But While initial Snapshot in am getting following error

Distributor Subsystem: Cannot continue the execution because the session is in the kill state.  error: 596

Same was working before with out any issues.

Can some one help me on this?

migrate replication to 2014 to different domain/servername, VLDB.

$
0
0

Task to migrate to 2014, servers have replication. Subscriptions are transnational, pull.

domain1.com: server1 is publisher, server2 is distributor and subscriber.

These are 2008R2 (yeah, gotta move it...)

Databases are large, so making snapshot and re-establishing subscription would be a trouble and quite likely not fast enough to fit into downtime window anyways.

We do not have much control over how the customer will move databases, so far they are not doing ms sql backup and restore. They are doing files snapshot on SAN and moving the data this way and attaching the databases to sql 2014 instances. Server names change, domain changes.

New servers are in new domain. Let's name it  domainnew.com

Servernew1.Domainnew.com will take databases from server1.domain1.com, and Servernew2.domainnew.com will take databases from server2.domain1.com

publisher and subscriber roles remain the same : servernew1 publisher, servernew2 distributor and subscriber. these are 2014.

To make it fun, domain1 and domainnew are trusting one another. Production servers server1 and server2 will be up after the move and they want to run it in parallel with the new system as a test/QA.

Security wise windows users from new domain already registered in production databases a while ago and working.

We will be able to shut down production systems, flow the data all the way through to replicated database and downstream (warehouses etc) before SAN snapshots will be taken and database files being copied.

What is needed is to reestablish pull subscriptions in new domain without doing snapshot and initializing subscriptions is a big question. Having the fact that old servers are not down, they will be up, and news servers can see those and wise versa (do not have control over that particular part... we may request temporary cut the link for maintenance window, that's about it).

We will not have ms sql backups during the move. Publisher database and subscriber are not clones, replicated data set is only the particular subset of tables, 1.5TB roughly.

What can we do if we have databases copied 'cold' on SAN level and attached to the new servers.

Redoing replication (kill old one. script publication, do snapshot and whole 9 yards is... very very slow, we will not likely if into maintenance window) is not fast enough.

We do not have full backup to restore in that process (their backup subsystem is very slow), the do it faster basically doing a form of file copy of mdf and ldf's.

Is there a way to create new replication in this case and synchronize without snapshot?

thanks

Cannot Remove Local Publication

$
0
0

Hi Folks,

I have two servers which both have IIS and SQL 2014 installed. One hosts our production website, and the other is a DR copy. The server names are WEB and DR-WEB, respectively.

I tried setting up SQL replication for the CMS DB from WEB to DR-WEB such that WEB is the publisher and DR-WEB is the distributor and subscriber. For one reason or another it wasn't working properly, and I decided it would probably work better as a push subscription, so I wanted to make WEB the distributor instead.

I set about removing the configuration I had created to try again, but (of course) have run into some issues since I probably didn't do it correctly. I was able to drop the distributor DB on DR-Web and remove the subscription object there, but I can't seem to remove the publication object on WEB.

If I rclick on the publication object on WEB and choose delete, I get an error saying:

"Could not connect to server 'DR-WEB' because 'WEB' is not defined as a remote server. Verify that you have specified the correct server name. (Microsoft SQL Server, error:18482)"

This error is kind of throwing me since WEB is the local server, and shouldn't be defined as remote. If I rclick on the publication object and choose properties -> Publication Access List, I get the same error. I've Googled this to death and have come up with various SQL Transact statements, but I'm not a DBA and it's a bit scary on a production server for someone who doesn't have a solid understanding of what they're doing.

Can anyone tell me how to get rid of this publication so I can try again? Thanks muchly,

ianc



Merge Replication taking very long time about 3 hours ( Upload Commands 3790 , Download Commands 3642 ) lot of conflicts

$
0
0

We are using merge replication to sync data between two remote sites. Its taking about 2 - 3 hours to replicate data and noticed mainly one table its taking very long time this table contains about (350K rows of data and contains a Foreign Key and Image Data Type - Mostly Null value in Image Column) Also the Other which FK refers too contain about 26 Million rows . I also noticed that we have some primary key and unique key constraints issues between the tables and its taking forever. Merge agent keeps trying to resolve the issues and takes about 1-2 minutes retrying it .

Can you please let me know how to speed up the merge replication and resolve these issues. Also snapshot is not being replicated 

Please let me know if more details are needed. I created indexes changed the Merge Agent Profile but still its very slow

Replication Monitor could not open the Detail Window

$
0
0

The publisher is running SQL Server 2008 R2 on a Server 2008 R2 box. The subscriber is running SQL Server 2012 on a Server 2012 box. I have tried launching the replication monitor from both servers but can't drill down into details on either instance. I have three publications and subscriptions and they all throw this error when trying to drill down into the details. I would post a picture but am unable to do so. 

Here are the error details

===================================

Replication Monitor could not open the Detail Window. (Replication Monitor)

===================================

Specified cast is not valid. (ReplicationMonitor)

------------------------------
Program Location:

   at Microsoft.SqlServer.Management.UI.PublicationDetailControl.ShowSubscriptionDetailWindow(Int64 rowIdx)

Replication Error

$
0
0

I am getting the below error in replication in my subscriber

An explicit value for the identity column in table 'dbo.l' can only be specified when a column list is used and IDENTITY_INSERT is ON. (Source: MSSQLServer, Error number: 8101)
Get help: http://help/8101
An explicit value for the identity column in table 'dbo.l' can only be specified when a column list is used and IDENTITY_INSERT is ON. (Source: MSSQLServer, Error number: 8101)
Get help: http://help/8101

How best to partition a table on subscriber ?

$
0
0

Hello,

There is a request from customer to implement partitioning on a very big and hot table (~ 1 TB with 2bn records) – As this table on the subscriber and receives the changes via Transaction Replication from highly available publisher database, replication reports some latency. Appreciate if someone shed light on two points.

  1. What is the best way to partition this table? I am considering it doing when latency is not much and will disable distribution agent during the activity to avoid blocking.
  2. If default escalation is changed to AUTO so to escalate lock to Partition level rather than to table level – will that of help?

Env: SQL Server 2012 Enterprise Edition

Thank you



Migrating Data from One server to Other

$
0
0

Hi There,

We have an existing web application of sales of customers in which the back end data is maintained in the form of sql databases. They are nearly 50 databases and we have a fresh server in which we have to work remote. Our client want us to Migrate the total databases from the existing server(SQL server 2008 R2) to the new server (SQL server 2016).

We have several DTS packages since the data is too old and we need to convert those DTS packages to SSIS packages, we are working with it. Our client is also planning to create two application in this new server so that total data should be centralized on one server. 

What are the points need to be considered while migrating the total data to the new server? Suggest us the best plan to migrate the data without any issues.   

Which Authentication is Best to make SQL Jobs Centralized?

$
0
0

Hi there,

We are planning to migrate all SQL databases, SQL agent jobs, Replications, etc; to the new server for our new application. Can you please suggest me the best authentication so that all the SQL Agent Jobs should be Centralized.

Thank you. 

Merge Replication (ROWGUID Issue)

$
0
0

HI,

If merge replication creation happen on empty subscription database then no issues. However on subscription which has data, even though its same as  publisher, it gives primary column conflict.

My Findings:
1. If replication created on empty subscription database, Rowguid column has same value. Runs successfully.
2. If replication created on subscription database which has data, Replication gives primary column conflict.

For the second scenario we need to explicit create rowguid column which internally creates its  guid values.

I need help on second scenario, which is quite possible to delete and recreate replication in production and need solution for same.

Thanks in advance.

Restoring a publication database to test instance

$
0
0

Hello

I have a publication database with merge replication. I used a backup of this database to refresh a test database (not replicated) and notice the 'ROWGUID' after the restore was no longer there. Is this normal behavior and does anyone have a link to an article or documentation?

Thanks

Will sp_repldone help my issue?

$
0
0

I keep getting this issue.  Will sp_repldone stop this?  I delete the record and it keeps giving me this error.  

If I stop synchronization and start it again, why would the performance start saying "Performance Critical"?

$
0
0
If I stop synchronization and start it again, why would the performance start saying "Performance Critical"?

Best Method for tracking local changes to tables in Azure Sql Database

$
0
0
We are building a Data warehouse in Azure and need a method to capture local server changes and apply them to Sql Data base in Azure, any thoughts on the best method to do this?

Allow Intitialize with Backup +Timestamp problem

$
0
0

Hi

 I create transactional replication with allow initialize backup =true  the problem is in my database all the tables have timestamp ,so it could not sync.

i drop all the timestamp columns in subscriber database and add Timestamp Varbinary(8) and start sync, again i received the same error.

Cannot insert an explicit value into a timestamp column. Use INSERT with a column list to exclude the timestamp column, or insert a DEFAULT into the timestamp column.

Please help me to solve.


Thanks & Regards Manoj

Unable to connected to SQL Failover Cluster instance on Azure from other SQL host in cluster

$
0
0

When I attempt to connect to the SQLCluster called BagCluster2 I get an error, here is the error exactly:

TITLE: Connect to Server
------------------------------

Cannot connect to BagCluster2\MSSQL.

------------------------------
ADDITIONAL INFORMATION:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) (Microsoft SQL Server, Error: -1)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%20SQL%20Server&EvtSrc=MSSQLServer&EvtID=-1&LinkId=20476

------------------------------
BUTTONS:

OK
------------------------------

But the problem I think has to do with Internal Load Balancer. I have the SQL Servers on Resource Manager VM's on the same Availability group and setup with the loadbalacer. I used the following guide:

https://www.youtube.com/watch?v=OZs5dk8iZnQ

All firewalls are turned off and I cant seem to connect from the SQL Server that is not the current owner of the Failover Cluster Resource. Any suggestion would be appreciated.

sql replication in standard edition .. 2012 -- can we do row level data push or pull

$
0
0

Hi Team,

Have a Query in Replication.

Can we use replication to pull selective data (Row Level) from publisher to subscriber?

Like in DB, among multiple  tables, I select few tables, and amoung selected tables, I select few columns . and amoung this now the challenge is , choosing rows, based on empid , like only if right empid is been loaded in publisher , those rows has to be copied to destination. If not it has to ignore .

Can we do it please.. 


hemadri

Transactional Replication for Always On Availability Groups

$
0
0

Hi,

I have the following environment:

  • SERVER2014AGPrimary - SQL Server 2014, part of Availability group and being the primary replica;
  • SERVER2014AGSecondary - SQL Server 2014, part of Availability group and being the secondary replica;
  • SERVER2014Distributor - SQL Server 2014 and hosting the remote distributor;

Both publisher and subscriber databases are in the same SQL instance.

I follow the guide "Configure Replication for Always On Availability Groups (SQL Server)" and it works as expected when there is a manual failover.

However, one of the requirements is working in an event of disaster (e.g. SERVER2014AGPrimary never being recovered again after a failover).

For replicate that situation, I have done the following:

  • Failover from SERVER2014AGPrimary to SERVER2014AGSecondary;
  • Stop SQL Server service in SERVER2014AGPrimary;

In such scenario, replication is not working. But, when started SQL Server service in SERVER2014AGPrimary replication works again.

Am I missing something? Or is this a limitation of Replication?

Thanks,

Filipe

How to replicate a new table to secondary automatically.

$
0
0

We have a transactional replication  in our environment.

Frequently,  adds the new table to that source server.Can anyone advise me how to automate this process.

Requirement: When the user adds the table, it should automatically add to the snapshot and replicate to the secondary server.

Please let me know if there is any possibility to  fix the issue,


Viewing all 4054 articles
Browse latest View live




Latest Images