June 7, 2019 at 11:22 am
I am setting up log shipping for a database and have hit an error at the "monitor server" stage. I used the GUI to create the T-SQL that needs to be executed and it generated:
EXEC msdb.dbo.sp_processlogshippingmonitorsecondary
@mode = 1
,@secondary_server = N'SECONDARY'
,@secondary_database = N'DBNAME'
,@secondary_id = N''
,@primary_server = N'PRIMARY'
,@primary_database = N'DBNAME'
,@restore_threshold = 45
,@threshold_alert = 14420
,@threshold_alert_enabled = 1
,@history_retention_period= 5760
,@monitor_server = N'MONITOR'
,@monitor_server_security_mode = 1
However when running this command I get the error:
Msg 8114, Level 16, State 5, Procedure sp_processlogshippingmonitorsecondary, Line 0 [Batch Start Line 198]
Error converting data type nvarchar to uniqueidentifier.
I'm guessing this is coming from the empty string associated with the @secondary_id parameter but as this is a required parameter I'm unsure what value it needs to be?
Thanks.
June 7, 2019 at 6:54 pm
Found the answer. On the secondary server run:
SELECT [secondary_id] FROM [msdb].[dbo].[log_shipping_monitor_secondary] WHERE [secondary_server] = N'SECONDARY' AND [secondary_database] = N'DBNAME'
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply