Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to add the -Output parameter to my log reader agent for transactional replication and getting this error:

Msg 21805, Level 16, State 1, Procedure sp_MSvalidate_agent_parameter, Line 92
The agent profile creation process cannot validate the specified agent parameter value.
'K:\Inst06_TempDB\MSSQL10.INST06\MSSQL\Log\ReplOutput-LogReaderAgent.txt' is not a valid
value for the '-Output' parameter. The value must be an integer. Verify that replication
is installed properly and that sp_add_agent_parameter is invoked with a valid value. shows that -Output expects a path, not an integer as the error message says.

Pub & Sub are both v9.0.4211, Dist is v10.0.2723

My Script (run at distributor):

EXEC sp_change_agent_parameter @profile_id = 18
                              ,@parameter_name = '-Output'
                              ,@parameter_value = 'K:\Inst06_TempDB\MSSQL10.INST06\MSSQL\Log\ReplOutput-LogReaderAgent.txt'
EXEC sp_change_agent_parameter @profile_id = 18
                              ,@parameter_name = '-OutputVerboseLevel'
                              ,@parameter_value = '2' --[0|1|2|3|4] default 2
share|improve this question

That link is for logread.exe. Checking the page for the SPROC, see:

I'm wondering if the hyphen is needed, as it is not listed like that on the SPROC's page.

share|improve this answer
hyphen works for other options, but not this one. – Eric Humphrey - lotsahelp Aug 1 '11 at 19:47

-OutputMessageFile instead of -Output.


USE msdb
FROM MSagentparameterlist;
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.