windows - 注销服务器时任务计划程序作业失败
问题描述
我通过任务计划程序创建了一个 PowerShell 脚本。这个 ps1 基本上在 SQL 服务器中执行存储过程,然后刷新 Excel 表以获取最新数据。如果我已登录服务器,则任务计划程序作业运行良好,但当我从服务器注销时,它会失败并出现以下错误。
New-Object : Retrieving the COM class factory for component with CLSID
{00024500-0000-0000-C000-000000000046} failed due to the following error: 8000401a The server
process could not be started because the configured identity is incorrect. Check the username and password. (Exception from HRESULT: 0x8000401A).
注意:我已经在任务计划程序中完成了此设置:“无论用户是否注销都运行”,所以这不是问题。
解决方案
推荐阅读
- c++ - 如何在 QComboBox 中显示与列表文本不同的选定文本?
- c11 - MPSC环形缓冲区的DPDK实现
- c# - c# 中的 Process 类是非托管资源吗?
- python-3.x - 如何使用 ROS 2 在 python 节点中发布批量图像?
- python - Matplotlib 设置不同图形的相同框大小
- c - 为什么代码不检查函数中的条件
- reactjs - 在 React 中提交登录时,我在 (Localhost)URL 中获取我的密码和电子邮件作为查询字符串吗?
- reactjs - 在 Reactjs 中切换按钮的状态
- python - 在python中根据另一个子列表中的相应权重对子列表进行排序
- java - 无法解析 Cargo 跟踪器应用程序的依赖项和插件