Showing posts with label wizards. Show all posts
Showing posts with label wizards. Show all posts

Wednesday, March 21, 2012

Replication problem in SQL Server 2000

Hi all SQL Server experts!

I have created replication on my two servers (production and backup servers). I used wizards to create it and then generated SQL script for deleting and creating replication. For another task I came across the command sp_removedbreplication 'dbname' and I tried to use that for removing replication more easily on the servers. It seemed to not remove everything on the production server and whenever I install replication now, either by using wizards or my generated SQL scripts I get an error icon (red circle with a black X in it) on my Replication Monitor all the way down to Publisher and the publication named with the computer name. Also this icon is on Agents and Log Reader Agents but not on the actual agent.

Something must have happened when using sp_removedbreplication 'dbname' and I can't fix it. The replication works properly but i wish to not have the error icons.

Does anyone know how the error icons can be removed?

Best,
/M

The cleanest way and supported way is to drop the distributor and recreate it from scratch. However you can also look at the following tables in distribution database and delete any rows that reference your deleted publications (but take a backup of the distribution database first, and note that manually deleting these tables is unsupported):

MSpublications

MSsubscriptions

MSarticles

|||

I have checked these tables and they don't have anything that don't exist in them.

I have also dropped everything that has to do with replication and also the distribution database to use my scripts and install replication again. The replication works fines but there are still error icons on the folders. Only on the folders though and not on the actual items, e.g. agents. I am thinking of reinstalling the SQL Server. Might it be because SQL Server has replaced the actual icons with error icons and "lost" the orignial ones?

My scripts for installing replication has always worked but it is after I have used sp_removedbreplication on the distributor/publisher that these icons occur when I install replication, including using the wizards.

Best,
/M

|||Did you try disconnecting from the distributor and reconnecting to it. Sometimes the refresh of the data can cause such misbehavior. Also try restarting the sql server.|||

When deleting subscription, it's replication job may still remain. You can find it in SQL Server Agent Jobs list (in Enterprise Manager: [DB]->Management->SQL Server Agent->Jobs).

Name of the job consists of Publisher and Subscriber names. When you re-create a subscription, probably same name is generated, and job creation fails.

Use sp_delete_job stored procedure to delete the job.

|||

Thank you very much. That solved my problem.

Best,
/M

Replication problem in SQL Server 2000

Hi all SQL Server experts!

I have created replication on my two servers (production and backup servers). I used wizards to create it and then generated SQL script for deleting and creating replication. For another task I came across the command sp_removedbreplication 'dbname' and I tried to use that for removing replication more easily on the servers. It seemed to not remove everything on the production server and whenever I install replication now, either by using wizards or my generated SQL scripts I get an error icon (red circle with a black X in it) on my Replication Monitor all the way down to Publisher and the publication named with the computer name. Also this icon is on Agents and Log Reader Agents but not on the actual agent.

Something must have happened when using sp_removedbreplication 'dbname' and I can't fix it. The replication works properly but i wish to not have the error icons.

Does anyone know how the error icons can be removed?

Best,
/M

The cleanest way and supported way is to drop the distributor and recreate it from scratch. However you can also look at the following tables in distribution database and delete any rows that reference your deleted publications (but take a backup of the distribution database first, and note that manually deleting these tables is unsupported):

MSpublications

MSsubscriptions

MSarticles

|||

I have checked these tables and they don't have anything that don't exist in them.

I have also dropped everything that has to do with replication and also the distribution database to use my scripts and install replication again. The replication works fines but there are still error icons on the folders. Only on the folders though and not on the actual items, e.g. agents. I am thinking of reinstalling the SQL Server. Might it be because SQL Server has replaced the actual icons with error icons and "lost" the orignial ones?

My scripts for installing replication has always worked but it is after I have used sp_removedbreplication on the distributor/publisher that these icons occur when I install replication, including using the wizards.

Best,
/M

|||Did you try disconnecting from the distributor and reconnecting to it. Sometimes the refresh of the data can cause such misbehavior. Also try restarting the sql server.|||

When deleting subscription, it's replication job may still remain. You can find it in SQL Server Agent Jobs list (in Enterprise Manager: [DB]->Management->SQL Server Agent->Jobs).

Name of the job consists of Publisher and Subscriber names. When you re-create a subscription, probably same name is generated, and job creation fails.

Use sp_delete_job stored procedure to delete the job.

|||

Thank you very much. That solved my problem.

Best,
/M

Saturday, February 25, 2012

Replication Job Cleanup

Over the past couple of years, I have added & removed publications &
subscriptions, usung the wizards the come with SQL 2000. Recently we
had a problem with the dBs getting backed up and when I peered into the
SQL Server Agent->Jobs folder, there were many many more jobs than I
had publications & subscriptions, in fact some for tables that no
longer existed.
So my question is this. Is there a SP somewhere that will clean up all
the 'old' stuff without messing up all the stuff that is currently
working.
AHIA,
Larry...
No. For the most part these objects consume very little space and
replication won't reuse them or get confused by their existence.
This being said you can query sysmergearticles and get an idea of what is
currently in use on your publisher/subscriber. Again I would be adverse to
touching a production system in case I whack something - unless of course I
am a consultant as this might mean considerable overtime for me when things
go south.
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
"LPR-3rd" <lreames@.gmail.com> wrote in message
news:1130949038.398739.282220@.g44g2000cwa.googlegr oups.com...
> Over the past couple of years, I have added & removed publications &
> subscriptions, usung the wizards the come with SQL 2000. Recently we
> had a problem with the dBs getting backed up and when I peered into the
> SQL Server Agent->Jobs folder, there were many many more jobs than I
> had publications & subscriptions, in fact some for tables that no
> longer existed.
> So my question is this. Is there a SP somewhere that will clean up all
> the 'old' stuff without messing up all the stuff that is currently
> working.
> AHIA,
> Larry...
>
|||Hillary,
What are you saying? What are you implying? Would a consultant
really do that? Who me? Never!!!!
As always, thanks for your impartial advice!!!
Larry...