我在日志传送作业中保留期限到期后没有删除旧日志文件时遇到问题(下面的错误信息)
SQL Servers Service帐户显然可以访问该文件夹,因为它可以创建备份文件。我怀疑可能是Job的删除部分是在SQL Agent的凭据下执行而不是SQL Server服务的凭据。但是,我无法找到任何信息来证实这一假设。
2016-07-02 17:15:01.73 Deleting old log backup files. Primary Database: 'DBNAME'
2016-07-02 17:15:01.77 *** Error: Could not delete old log backup files.(Microsoft.SqlServer.Management.LogShipping) ***
2016-07-02 17:15:01.77 *** Error: Access to the path '\\SERVERNAME\LOGFILEBACKUPPATH' is denied.(mscorlib) ***
2016-07-02 17:15:01.78 The backup operation completed with errors. Primary Database: 'DBNAME', Log Backup File: '\\SERVERNAME\PATHTOLOGGILE'
2016-07-02 17:15:01.79 ----- END OF TRANSACTION LOG BACKUP -----