SansSQL: Publisher

Wednesday, July 17, 2013

Error while configuring Publisher - SQL Server could not connect to the distributor using the specified password

Recently I was trying to configure replication on one of my test bed and in this scenario there are 3 servers, one for Publisher, one for Distributor and the other for Subscriber.
All went well while configuring the distributor but when I was trying to configure the publisher,

Tuesday, December 25, 2012

Replication Architecture - Part 2

Let me get straight into the topic "Replication Architecture - Part 1"discussed last time; about the working of replication and then the entities involved in any replication model for that matter. We also did a understanding on publishing industry in comparison with replication which helped us in identifying the entities.

Following are the same:
  • Publisher
  • Distributor
  • Agent
  • Subscriber
  • Articles
  • Publications
  • Subscriptions
So, let us get into each of this with respect to Replication.
A SQL server instance can be configured as Publisher or Distributor or subscriber.


Publisher: In simple terms, Publisher is the server on which the "Source" database resides. It is the main source for data and also identifies what data should be distributed across.

Distributor: gathers all the published data and holds the same until it sends it across to all the registered subscribers. It is also referred to as "Bridge" between publisher-subscriber and can support multiple publisher and subscriber concept.

Subscriber: Is the final destination on which data has to be transmitted.

Articles: This is the basic unit of replication. An article identifies a database object that is included in a publication. A publication can contain different types of articles, including tables, views, stored procedures, and other objects.

Publication: A publication is a collection of one or more articles from one database. The grouping of multiple articles into a publication makes it easier to specify a logically related set of database objects and data that are replicated as a unit.

Subscription: A subscription is a request for a copy of a publication to be delivered to a Subscriber. The subscription defines what publication will be received, where, and when. There are two types of subscriptions, push and pull.

Agent: An agent is a median which identifies the changes at publisher and transfers those changes to subscriber.
There are different agents in replication,
  • Distribution Agent
  • Log Reader Agent
  • Merge Agent
  • Queue Reader Agent
  • Snapshot Agent

Monday, December 24, 2012

Replication Architecture - Part 1

Replication was something which I always wanted to explore... luckily had the opportunity of doing just that. To start off with anything that is new, we need to understand the "Architecture" and also working.

I have tried to put my understanding in words on the "Replication Architecture".

First of all, What is Replication?
In simple terms: Replication is the process of sharing data between databases in different locations. Using replication, we can create copies of a database and share the copy with different users.  This allows to make changes to local copy of the database and later synchronize the changes to the source database.

Next Question would be... Why do we opt for Replication?
Again, there can be many reasons for this; I have tried to capture few very valid reasons.
The primary concern for any organization is often the protection and availability of its data. Without reliable access to secure and relevant data, the smooth operation of a company comes to painful, unprofitable halt. Data should not only be secure, but also be accessible after a system or catastrophic failure. Replication - offers this accessibility.
In addition, Database replication can also supplement disaster-recovery plans by duplicating the data from a local database server to a remote database server. If the primary server fails, applications can switch to the replicated copy of the data and continue operations.

Now, we understand What is Replication and Why do we opt for Replication... The next would be to understand "How does Replication work", "What are the common entities used in deciding the type of replication?", "What are the types of Replication available or rather provided by MS" and much more...

So, let's move on understanding "How does Replication work":

Microsoft SQL server uses publishing industry model to represent the components and processes in replication architecture. The working is also similar to how publishing industry works(we can think of "Daily Newspaper as an example).
Publishing industry publishes Magazines/Books; there are Distributors and Agents who carry these publications to the Subscribers. Subscribers of the magazine obtain copies of the publication and read the articles of interest to them; this is exactly how the SQL Server Replication model works.

We can identify the following Entities for the SQL Server replication model.

Publisher
Distributor
Agent
Subscriber
Articles
Publications
Subscriptions

We will start getting into each of the above listed entities in my next blog... till then enjoy reading and also get some kind of know-how on types of replication provided by MS SQL Server!

Ads