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

Transactional replication on SQL 2012 and security issue

$
0
0

Hi

    Recently I've migrated from SQL 2008 to 2012. My replcation was fine, all data was flowing from publisher to all subscribers also ddl statements replicates well. But today there was a need for changing filter in one article so I dropped (executed sp_dropsubscription and sp_subscription_cleanup) subscription (only the one that I was changing), next I've changed filter (executed sp_articlefilter and sp_articleview) and as last step added subscription (executed sp_addsubscription and sp_addpushsubscription_agent). After that all publications in replication monitor turned red. The problem was in log reader agent - after making changes described earlier log reader agent begins throwing exeption like below:

The process could not execute 'sp_MSadd_replcmds' on 'DEVW2K8X64\DEVW2K8X64'. (Source: MSSQLServer, Error number: 1007)
Get help: http://help/1007
Only members of the sysadmin fixed server role can perform this operation. (Source: MSSQLServer, Error number: 1007)
Get help: http://help/1007

I've found the place where it throws the exception. Procedure sp_replcmds executes in its body procedure sp_MSsetupnosyncsubwithlsnatdist. In sp_MSsetupnosyncsubwithlsnatdist on line 97 is security check like below:

if (isnull(is_srvrolemember('sysadmin'),0) = 0)
    begin
        raiserror(21089, 16, -1)
        return 1
    end

Can anyone tell me how to walkaround this issue? On SQL 2008 there ware no need for adding login to sysadmin role - changing owner of proper databases was enough. Has it changed in SQL 2012 or is it some kind of issue that will be fixed?

EDIT: Yes, I have SP1 installed



Viewing all articles
Browse latest Browse all 4054

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>