Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sagitariusmzi
Posting Yak Master
113 Posts |
Posted - 2009-01-21 : 23:45:53
|
Due to Power Failure, my Database has gone into suspect modeHow could i take the Database live ? |
|
lionofdezert
Aged Yak Warrior
885 Posts |
Posted - 2009-01-22 : 01:03:01
|
http://gargmanoj.wordpress.com/2008/07/17/how-to-repair-a-sql-server-2005-suspect-database/ |
 |
|
sagitariusmzi
Posting Yak Master
113 Posts |
Posted - 2009-01-22 : 03:00:27
|
i applied the following but this doesn't worked for meEXEC sp_resetstatus 'DBname';ALTER DATABASE Bname SET EMERGENCYDBCC checkdb('DBname')ALTER DATABASE DBname SET SINGLE_USER WITH ROLLBACK IMMEDIATEDBCC CheckDB ('DBname', REPAIR_ALLOW_DATA_LOSS)ALTER DATABASE DBname SET MULTI_USER |
 |
|
cshah1
Constraint Violating Yak Guru
347 Posts |
Posted - 2009-01-22 : 09:27:47
|
First of all, what does your SQL error log says...why it is marked suspect?There are several reasons your database is marked suspect. You went too far with an emergency more and checkdb with data loss. Have you restarted your SQL Server service before you put your db into emergency mode?after you use sp_resetstatus 'mydbname'; is it still marked as suspect..?It is important to now what went wrong (suspect database is not uncommon after unexpected power shut down) |
 |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-01-22 : 11:46:51
|
Or if that didn't work.Post full output of DBCC CHECKDB(mydbname) WITH No_INFOMSGS, ALL_ERRORMSGS in Data Corruption Topic. |
 |
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2009-01-22 : 13:12:12
|
You need to check the error log for entries that indicate why the database has been marked suspect.--Gail ShawSQL Server MVP |
 |
|
sagitariusmzi
Posting Yak Master
113 Posts |
Posted - 2009-01-23 : 00:59:28
|
The Database was marked suspect due to the accidental power failure.i restarted the Sql server service after excuting the scriptbut that won't help. |
 |
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2009-01-23 : 02:35:16
|
Once more with feeling...What does the SQL error log say? There will be detailed messages in there as to why the DB was marked suspect. I can't offer you any suggestions on getting the DB back without seeing those first.--Gail ShawSQL Server MVP |
 |
|
|
|
|