Transactional Replication on a SQL Managed instance as a subscriber with pull subscription

Nitya V 40 Reputation points
2024-05-16T12:03:46.98+00:00

We are doing a transactional Replication to a SQL Managed instance (subscriber) with pull subscription from On-Prem(Publisher/Distributor)

We are seeing uninitialized subscription on the replication monitor.

How can we troubleshoot this

Azure SQL Database
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,947 questions
{count} votes

4 answers

Sort by: Most helpful
  1. Zahid Butt 556 Reputation points
    2024-05-16T13:25:15.62+00:00

    Sorry! removing the text due to duplication.

    0 comments No comments

  2. Zahid Butt 556 Reputation points
    2024-05-16T14:35:03.2033333+00:00

    Hi,

    Please follow below instructions to get it resolved:

    The “Uninitialized subscription” message in the Replication Monitor typically indicates that the subscription has been created but the initial snapshot has not been applied to the subscriber. Here are some steps you can take to resolve this issue:

    1.     Generate the Initial Snapshot: Go to the publication in SQL Server Management Studio, right-click on it, and select “View Snapshot Agent Status”. Then, start the Snapshot Agent to generate the initial snapshot.

    2.     Apply the Snapshot to the Subscriber: Once the snapshot is generated, synchronize your subscription to apply the snapshot. This can be done by starting the Distribution Agent.

    3.     Verify Subscription Initialization: After applying the snapshot, check the Replication Monitor again to see if the subscription status has changed from “Uninitialized” to a status indicating that it is now synchronized.

    4.     Check for Errors: If the subscription remains uninitialized, check for any errors in the SQL Server Agent job history for the Distribution Agent job. Errors here can provide clues as to why the subscription is not initializing.

    5.     Reinitialize the Subscription: If necessary, you can reinitialize the subscription. This can be done by right-clicking the subscription in the Replication Monitor and selecting “Reinitialize Subscription”. Note that this will resend the snapshot and can be data-intensive.

    6.     Check Security Settings: Ensure that the account running the Distribution Agent has the necessary permissions on both the publisher and subscriber databases.

    Regards,


  3. LucyChenMSFT-4874 1,815 Reputation points
    2024-05-17T03:12:43.59+00:00

    Hi @Nitya V ,

    Thanks for your information.

    If the replication site is left without monitoring for a long time, and a failure occurred without any fix for more than three days, the replication site will be expired and the Subscription will be marked as uninitialized, waiting to be reinitialized again using a new snapshot.

    Please follow the steps below to troubleshoot the issue:

    • Reinitialize that Subscription by right-clicking on the Subscription under the Replication node -> Local Publications and expand the Publication, then choose the Reinitialize option and mark this Subscription for Initialization and make it ready to receive a new snapshot.
    • If the Subscription status stays Uninitialized after reinitializing it, check the Snapshot Agent job, using the Job Activity Monitor window, and see why it is failing.
    • Please post the detailed failure message to help us narrow down the issue and offer more support.

    Best regards,

    Lucy Chen


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our Documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    https://docs.microsoft.com/en-us/answers/support/email-notifications


  4. LucyChenMSFT-4874 1,815 Reputation points
    2024-05-20T05:45:15.57+00:00

    Hi @Nitya V ,

    Thanks for your feedback.

    Did you perform this action?

    Reinitialize that Subscription by right-clicking on the Subscription under the Replication node -> Local Publications and expand the Publication, then choose the Reinitialize option and mark this Subscription for Initialization and make it ready to receive a new snapshot.

    Did the Subscription status stay Uninitialized after reinitializing it?

    I need more detailed information and your actions so far to locate the issue. Thanks for your understanding, we are looking forward to hearing from you to assist further.

    If you see the Subscription status changed to Running, giving that it is waiting for the initial snapshot to start the synchronization process.

    To generate a new snapshot, right-click on the Publication, under the Replication node-> Local Publications, and select View Snapshot Agent Status option.

    From the opened window, click on the Start button to start the snapshot creating process. When the snapshot that contains all the Publisher articles created successfully, open the Replication Monitor again and check the status of the Subscription, where you will see that the snapshot is applied to the Subscriber and synchronized with the Publisher.

    We can see the detailed steps from this article. Hope this can help you well.

    If you have any confuse, feel free to share with us.

    User's image

    Best Regards,

    Lucy Chen


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our Documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    https://docs.microsoft.com/en-us/answers/support/email-notifications