I'm getting the following error whenever trying to create a new maintenance plan in the Management Studio:
TITLE: Microsoft SQL Server Management Studio
Exception has been thrown by the target of an invocation. (mscorlib)
ADDITIONAL INFORMATION:
Cannot find folder "\Maintenance Plans".
Cannot find folder "\Maintenance Plans".
BUTTONS:
OK
I'm running SQL 2005 SP2 Enterprise Edition, and I have database mirroring configured for all of my non-system databases (3 total). My primary database server is a 2-node cluster. I've tried this from both a remote machine and directly on the SQL server itself, with the same results. Could this have anything to do with the data mirroring? I didn't have this problem previous to setting that up, although I haven't tried creating a maintenance plan in quite a while either.
Here are the error message details:
===================================
Exception has been thrown by the target of an invocation. (mscorlib)
Program Location:
at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Microsoft.SqlServer.Management.DatabaseMaintenance.MaintDesignerMenuHandler.GetExistingPackageNames(String serverName, String userName, SqlSecureString securePassword)
at Microsoft.SqlServer.Management.DatabaseMaintenance.MaintDesignerMenuHandler.Invoke()
===================================
Cannot find folder "\Maintenance Plans".
Program Location:
at Microsoft.SqlServer.Dts.Runtime.Application.GetPackageInfos(String strFolder, String serverName, String serverUserName, String serverPassword)
===================================
Cannot find folder "\Maintenance Plans".
Program Location:
at Microsoft.SqlServer.Dts.Runtime.Wrapper.ApplicationClass.GetPackageInfos(String bstrPackageFolder, String bstrServerName, String bstrServerUserName, String bstrServerPassword)
at Microsoft.SqlServer.Dts.Runtime.Application.GetPackageInfos(String strFolder, String serverName, String serverUserName, String serverPassword)
Try this:
Code Snippet
-- Verify that the folder is missing:
Use msdb;
go
exec sp_executesql N'exec [msdb].[dbo].[sp_dts_getfolder] @.P1, @.P2',N'@.P1 nvarchar(17),@.P2 uniqueidentifier',N'Maintenance Plans','00000000-0000-0000-0000-000000000000'
-- If there is no Folder, then
-- Add the folder if missing:
exec sp_dts_addfolder '00000000-0000-0000-0000-000000000000','Maintenance Plans','08AA12D5-8F98-4DAB-A4FC-980B150A5DC8'
Regards,
Willfried
sql
No comments:
Post a Comment