SQL Server 2019 snapshot agent error
2022/8/8 2:24:12
本文主要是介绍SQL Server 2019 snapshot agent error,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!
1、日志错误提示
Microsoft OLE DB Driver for SQL Server: Unable to load msoledbsqlr.rll due to either missing file or version mismatch. The application cannot continue.
2、原因分析
This appears to be a common issue.
The advice you received about installing the latest OLE drivers is correct. However, even with the latest drivers installed the snapshot agent will still use the older version drivers that come with SQL Server 2019.
This has to do with the Path variable in your environment. Have a look at System Properties, Advanced System Settings, Environment Variables, System variables, Path.
Unless you have changed your defaults you will find %SystemRoot%\system32, %SystemRoot% at the top and C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\ further down.
What you will not find is a path reference to %SystemRoot%\SysWOW64\ and %SystemRoot%\SysWOW64\1033 which is where the latest OLE drivers get installed on 64 bit systems. The driver files are msoledbsql.dll and msoledbsqlr.rll
So, when the snapshot agent starts it will use the OLE driver files installed relative to its binary somewhere under the C:\Program Files\Microsoft SQL Server\ branch as it cannot find any others in the Path.
When you insert %SystemRoot%\SysWOW64\ and %SystemRoot%\SysWOW64\1033 into your system Path variable (make sure this is above any references to C:\Program Files\Microsoft SQL Server\...) and the restart your SQL Server instance you should find that your problem goes away.
3、解决方案
1>在环境变量中添加%SystemRoot%\SysWOW64\ 和%SystemRoot%\SysWOW64\1033两个变量,并且在sql server的所有变量之前。
2>重启电脑或者sql server服务。
转载自:https://social.msdn.microsoft.com/Forums/en-US/e2c23cda-9e78-4514-bae6-27c6d34767a4/sql-server-2019-snapshot-agent-error?forum=sqlreplication
这篇关于SQL Server 2019 snapshot agent error的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!
- 2024-01-08Docker下的SqlServer发布订阅启用
- 2023-06-05Docker安装MS SQL Server并使用Navicat远程连接
- 2023-05-25深入浅出 SQL Server CDC 数据同步
- 2023-05-12通过空间占用和执行计划了解SQL Server的行存储索引
- 2023-04-24以SQLserver为例的Dapper详细讲解
- 2022-11-30SQL server高级函数查询
- 2022-11-26SQL SERVER数据库服务器CPU不能全部利用原因分析
- 2022-11-21SQL Server 时间算差值/常用函数
- 2022-11-20调试Archery连接SQL Server提示驱动错误
- 2022-10-22SQL Server 完整、差异备份+完整、差异还原(详细讲解,规避错误)