Showing posts with label generate. Show all posts
Showing posts with label generate. Show all posts

Wednesday, March 28, 2012

Maintenance plan does not run

Hi - I have a strange situation where the Maintenance plan on a SQL 7, build 961 will not generate .BAK and .TRN files based on the maintenance plan (or at all). I have tried deleteing and recreating the maintenance plan, but, according to the system log, and to maintenance plan logs, the entire maintenance plan is not launching any tasks. However the application log whoes all the jobs as failing, but gives no furhter details.

However I have another server running build 623 that is working fine.

Any ideas from anyone? All help appreciated.Why use a maintenance plan - they give lots of problems.
Just schedule a backup job or jobs.
Have them call a stored procedure and put the backup statement in that.|||Here's the error from Eventlog:

SQL Server Scheduled Job 'Transaction Log Backup Job for DB Maintenance Plan 'Webmon1'' (0x42E6C45B360CD611935D0002B330ABF9) - Status: Failed - Invoked on: 2/8/02 4:10:46 PM - Message: The job failed. The Job was invoked by User XXXXXX\Administrator. The last step to run was step 1 (Step 1).|||What happens if you try the same backup using a backup command?

Monday, March 26, 2012

Maintenance Plan

Can you generate script for a maintenance plan?
I know how to script a job, I was wondering about a plan.
If not, whats the best way to record the configuration?
Thanks
LystraLook into the following tables in MSDB:

sysdbmaintplan_databases
sysdbmaintplan_history
sysdbmaintplan_jobs
sysdbmaintplans
sysjobhistory
sysjobs
sysjobs_view
sysjobschedules
sysjobservers
sysjobsteps|||Please forgive me, but what will looking into those tables get me?

Thanks

Lystra|||I think that when you script a maintenance plan, you get a GUID-like reference which is the unique identifier for the plan. There are some additional parameters which are included, but in general the script is not readable nor would it help in recreating a plan (because of the unique reference).

I generally try to build my plans in a similar fashion (checking off the same options). The only variation I may factor in is a different timing scheme (so that I minimize contention as the backups are being written to the network drive). Each server has a User database maintenance plan and a system database maintenance plan.

I then make notes somewhere so that in case I am hit by a Mack truck a new DBA could (hopefully) pick up and understand where I had left off.

This is okay in my environment where I have about 10-12 servers to manage. It gets a bit out of hand when you get into some of the hosted environs where there might be hundreds of servers to monitor.

Regards,

hmscott