Directory lookup for the file "xxx.mdf" failed with the operating system error 2

Directory lookup for the file "xxx.mdf" failed with the operating system error 2(系统找不到指定的文件。).

reason:

sql2005以后 禁用了xp_cmdshell存储过程

solution:

sp_configure 'show advanced options', 1
GO
RECONFIGURE
GO
sp_configure 'xp_cmdshell', 1
GO
RECONFIGURE
GO

原文地址:https://www.cnblogs.com/faeriesoft/p/4238538.html