Solved

sql server suspect

Posted on 2000-02-24
4
950 Views
Last Modified: 2008-02-01
after reboot server , a database in sql server 6.5 suspect. we try to turn it to emergency mode to made it available again . But we still can't access the database.

And in the event log ,error logged as follow:


The description for Event ID ( 17060 ) in Source ( MSSQLServer ) could
not be found. It contains the following insertion string(s): Error : 605,
Severity: 21, State: 1, Attempt to fetch logical page 1160 in database
'RERS_WS' belongs to object '1490104349', not to object 'ItemCategory'..


Any method to repair the database so we can access it again?

As I known , we can use 'bcp' program to
copy out the data from the database ,
how to use this command?
0
Comment
Question by:adragon218
4 Comments
 
LVL 8

Expert Comment

by:chigrik
ID: 2553836
Read about "My SQL Server database has been marked "suspect" - what can I do?"
http://www.ntfaq.com/ntfaq/sql29.html#sql29
0
 

Author Comment

by:adragon218
ID: 2556372
we have tried  to change it to emergency mode , but it still not work ,
we want to know how to change to normal state to recover the database
0
 

Expert Comment

by:flyindian7
ID: 2556451
Because the database has been marked suspect, its status must be reset. To do this, perform the following steps:


Use the supplemental stored procedure sp_resetstatus to reset the status of a suspect database. If you have not already done so, create this procedure by executing the Instsupl.sql script, found in the Mssql\Install directory. For more information on sp_resetstatus, see the "Resetting the Suspect Status" topic in the SQL Server Books Online.


Execute sp_resetstatus in the master database for the suspect database:
use master
go
sp_resetstatus <db_name>



Stop and restart SQL Server.


Verify that the database was recovered and is available.


Run DBCC NEWALLOC, DBCC TEXTALL, and DBCC CHECKDB.


This might help.....we have had a suspect database before and the reset seem to work...hope u can recover ur database...good luck

0
 
LVL 1

Accepted Solution

by:
vujos earned 45 total points
ID: 2556481
Hi,

You realy hit the hard one. Error 605 means that links in the logical structure of your database are corrupt (this means that the ponter in the table RERS_WS page 1160 points to page in table ItemCategory instead to next page in RERS_WS).

You have one of 3 posibilities :

1) As you correctly stated if you are lucky and you know the number of rows first thing to do will be (read microsoft note Q165918) run following comand to try to return database to normal mode

UPDATE master..sysdatabases SET status = status ^ 256 WHERE name = <dbname>
 
If the database still goes back into suspect modeand you have no recent backup, then you can get information out of the database by putting it into emergency mode. If you do this, extract the data/objects out with bcp/transfer manager and then rebuild the database. Note that the data may be corrupt or transactionally inconsistent.
 
Following command will ? put database in emergency mode

UPDATE master..sysdatabases SET status=-32768 WHERE name='<dbname>'

For BCP usage follow link http://support.microsoft.com/support/kb/articles/q67/4/09.asp

2) Microsoft support will be able to help you if there is only one "brake" in page links (by using undocumented DBCC options).

3) Restore from last know good backup.

Hope this helps
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Let's review the features of new SQL Server 2012 (Denali CTP3). It listed as below: PERCENT_RANK(): PERCENT_RANK() function will returns the percentage value of rank of the values among its group. PERCENT_RANK() function value always in be…
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

747 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now