Solved

Error in Satabase  Maintenance plan

Posted on 2004-04-30
8
1,392 Views
Last Modified: 2012-05-04
The maintenance plan for daily back up failed.
I have SQL 2000 on Windows Server 2003.
This is the report:

Microsoft (R) SQLMaint Utility (Unicode), Version Logged on to SQL Server 'M2MERP' as 'lmc\sqladmin' (trusted)
Starting maintenance plan 'DAILY_MASTER_INTEGRITY' on 4/30/2004 4:00:00 AM
[Microsoft SQL-DMO (ODBC SQLState: 42000)] Error 5058: [Microsoft][ODBC SQL Server Driver][SQL Server]Option 'SINGLE_USER' cannot be set in database 'MASTER'.
[Microsoft][ODBC SQL Server Driver][SQL Server]sp_dboption command failed.
[1] Database master: Check Data and Index Linkage...
[Microsoft SQL-DMO (ODBC SQLState: 42000)] Error 7919: [Microsoft][ODBC SQL Server Driver][SQL Server]Repair statement not processed. Database needs to be in single user mode.

    The following errors were found:

[Microsoft][ODBC SQL Server Driver][SQL Server]Repair statement not processed. Database needs to be in single user mode.
    ** Execution Time: 0 hrs, 0 mins, 1 secs **

[2] Database model: Check Data and Index Linkage...

    ** Execution Time: 0 hrs, 0 mins, 1 secs **

[Microsoft SQL-DMO (ODBC SQLState: 42000)] Error 5070: [Microsoft][ODBC SQL Server Driver][SQL Server]Database state cannot be changed while other users are using the database 'msdb'
[Microsoft][ODBC SQL Server Driver][SQL Server]ALTER DATABASE statement failed.
[Microsoft][ODBC SQL Server Driver][SQL Server]sp_dboption command failed.
[3] Database msdb: Check Data and Index Linkage...
[Microsoft SQL-DMO (ODBC SQLState: 42000)] Error 7919: [Microsoft][ODBC SQL Server Driver][SQL Server]Repair statement not processed. Database needs to be in single user mode.

    The following errors were found:

[Microsoft][ODBC SQL Server Driver][SQL Server]Repair statement not processed. Database needs to be in single user mode.
    ** Execution Time: 0 hrs, 0 mins, 1 secs **

Deleting old text reports...    0 file(s) deleted.

End of maintenance plan 'DAILY_MASTER_INTEGRITY' on 4/30/2004 4:00:01 AM
SQLMAINT.EXE Process Exit Code: 1 (Failed)

How do I correct this error?

Thank you,

0
Comment
Question by:cosio
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
8 Comments
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 10959736
Do not check the box that reads "Attempt to repair any minor problems"
0
 

Author Comment

by:cosio
ID: 10959830
What are the consequences of checking the box? I mean other that cousing this error to happen, why does the plan fails? Can anyone give me a brief explanation?
I appreciate
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 250 total points
ID: 10959927
The consequences of checking the box is that the database needs to go into Single User mode.  If this is a multiuser database (and 99% are) that will mean it will fail if any user is currently active.  Worse still, even if there are not (and that is a risk in itself) there is a chance that it will remain in Single User mode.  See here:
FIX: Database Remains in Single User Mode with the Database Maintenance Plan Option "Repair Any Minor Problems"
http://support.microsoft.com/default.aspx?scid=kb;en-us;259551

Again, not a good thing.
0
Free eBook: Backup on AWS

Everything you need to know about backup and disaster recovery with AWS, for FREE!

 
LVL 34

Expert Comment

by:arbert
ID: 10960473
agree with acperkins totally.....Personally, I think it's a bad idea to let SQL Server attempt any repairs anyway until you have a report and know what the damage is.  Sometimes the repair makes things worse....
0
 

Author Comment

by:cosio
ID: 10980110
A MSSQL "expert" told me that I need to check "Attempt to repair any minor problems" when doing backups.
0
 
LVL 34

Expert Comment

by:arbert
ID: 10980132
So why the question here if you already have an "expert"?
0
 
LVL 34

Expert Comment

by:arbert
ID: 10980201
0
 

Author Comment

by:cosio
ID: 10981449
What I have been told is to check "attempt to repai any minor problems in the productions databases maintenance plan.
The person who installed SQL in this place suppose to be an "expert."

Obviouly I like to heart other people with experience in SQL. So far what you guy are telling me makes a lot more sense that what I  have been told.

For the record, it is not my "expert", this person is a consultant that this place hired before me. I am new here taking care of the company databases. I post the question because I have some doubts about the way the consultant "expert" implements some things around here.

thank you
0

Featured Post

Webinar: Aligning, Automating, Winning

Join Dan Russo, Senior Manager of Operations Intelligence, for an in-depth discussion on how Dealertrack, leading provider of integrated digital solutions for the automotive industry, transformed their DevOps processes to increase collaboration and move with greater velocity.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question