Welcome to dbFreaks.com!
FAQFAQ    SearchSearch      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

Database Restore Problem SQL Server 2005

 
   Database Help (Home) -> Programming RSS
Next:  Return Single Value  
Author Message
Nizham

External


Since: Dec 04, 2006
Posts: 2



(Msg. 1) Posted: Mon Dec 04, 2006 9:45 am
Post subject: Database Restore Problem SQL Server 2005
Archived from groups: microsoft>public>sqlserver>programming (more info?)

Hi

OS Windows server 2003 SP1
SQL Server 2005 Slandered Edition

We try to restore the backup from the bak file and it is giving the
following message

System.Data.SqlClient.SqlError : Restore Detected an error on page (0:0) in
database "Database_Name" as read from backup set (Microsoft.Sql.Server.Smo)

Any one help me to solve this problem

Regards
Nizham

 >> Stay informed about: Database Restore Problem SQL Server 2005 
Back to top
Login to vote
Uri Dimant

External


Since: Aug 24, 2003
Posts: 1744



(Msg. 2) Posted: Mon Dec 04, 2006 9:45 am
Post subject: Re: Database Restore Problem SQL Server 2005 [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi
Can you provide a little bit more about .BAK file? Does ot come from SQL
Server 2000 or SQL Server 2005?
It seems that .BAK file is corrupt. Have you dowloaded it from anywhere?







"Nizham" wrote in message

> Hi
>
> OS Windows server 2003 SP1
> SQL Server 2005 Slandered Edition
>
> We try to restore the backup from the bak file and it is giving the
> following message
>
> System.Data.SqlClient.SqlError : Restore Detected an error on page (0:0)
> in database "Database_Name" as read from backup set
> (Microsoft.Sql.Server.Smo)
>
> Any one help me to solve this problem
>
> Regards
> Nizham
>

 >> Stay informed about: Database Restore Problem SQL Server 2005 
Back to top
Login to vote
Nizham

External


Since: Dec 04, 2006
Posts: 2



(Msg. 3) Posted: Mon Dec 04, 2006 10:45 am
Post subject: Re: Database Restore Problem SQL Server 2005 [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi

Thanks for your imm response

It is 2005 backup file. Actually what happen was the server hard disc was
crashed and we recovered all the data there was are lot of bak files (Auto
backup for last 1 month) . We tried all the files it is giving the same
error message. We tried to attach the Database using sp_attach command by
taking the mdf and ldf files it also giving error message.

Will you please help us recover the data

Regards
Nizham

"Uri Dimant" wrote in message

> Hi
> Can you provide a little bit more about .BAK file? Does ot come from SQL
> Server 2000 or SQL Server 2005?
> It seems that .BAK file is corrupt. Have you dowloaded it from anywhere?
>
>
>
>
>
>
>
> "Nizham" wrote in message
>
>> Hi
>>
>> OS Windows server 2003 SP1
>> SQL Server 2005 Slandered Edition
>>
>> We try to restore the backup from the bak file and it is giving the
>> following message
>>
>> System.Data.SqlClient.SqlError : Restore Detected an error on page (0:0)
>> in database "Database_Name" as read from backup set
>> (Microsoft.Sql.Server.Smo)
>>
>> Any one help me to solve this problem
>>
>> Regards
>> Nizham
>>
>
>
 >> Stay informed about: Database Restore Problem SQL Server 2005 
Back to top
Login to vote
Uri Dimant

External


Since: Aug 24, 2003
Posts: 1744



(Msg. 4) Posted: Mon Dec 04, 2006 10:45 am
Post subject: Re: Database Restore Problem SQL Server 2005 [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Nizham

I'm almost sure that your .BAK file is corrupt. Open SSMS and try manually
to attach the .MDF,LDF files , if it does not help , see the below script
(I have not tested it on SS2005 , but it works fine on SS2000)

shutdown sql
move the current database file or rename it
restart sql server
create a new database of the same name and log file and location as the old
database and log file
get rid of the old database.
you may be able to right click delete it in this situation or used
sp_removedb
create a new database of the right size and shape with correct log and data
file locations
stop sql
rename the new databases.mdf or delete it if you don't have enough space -
do not touch the .ldf
move back in the old database .mdf file or rename it back again
restart sql server

it should come up suspect
--------------------------------
1. From a query window, set the status so that you can update the system
tables by running the following query:
use Master
go
sp_configure "allow", 1
go
reconfigure with override
go

2. Then set the status of the DB that is giving you the problem (XXXXX) into
Emergency Mode by running the following query:

update sysdatabases set status = 32768 where name = '<DBName>'
go
checkpoint
go
shutdown with nowait
go

3. Go into the data directory (MSSQL7\DATA) and rename the log file
associated
the DB in question (XXXX.ldf) to some
temporary name, such as XXXX.TMP.

4. Exit the query window.
5. Then start up SQL Server from a DOS command window by issuing:
sqlservr -c -T3608 -T4022.
6. Bring up another query window and verify that the DB is in emergency mode
by issuing:
select Name, Status from Sysdatabases where name = '<DB_Name>'

7. Verify that the status is 32768. If it is, then issue the query:
dbcc traceon(3604)
dbcc rebuild_log('<DB_Name>','<log_filename>') <--- You will need
the quotation marks
REBUILD_LOG should take less than 5 minutes even on a very large
database. It should complete with the message
DBCC execution completed
8. Take the database out of bypass recovery mode by issuing the command
update sysdatabases set status = 0 where name = '<DBName>'
9. Exit the query window and then shutdown (Ctrl-C in the DOS window) and
restart SQL server. Verify the status of the
database by running DBCC NEWALLOC and DBCC CHECKDB on the database.


"Nizham" wrote in message

> Hi
>
> Thanks for your imm response
>
> It is 2005 backup file. Actually what happen was the server hard disc was
> crashed and we recovered all the data there was are lot of bak files (Auto
> backup for last 1 month) . We tried all the files it is giving the same
> error message. We tried to attach the Database using sp_attach command
> by taking the mdf and ldf files it also giving error message.
>
> Will you please help us recover the data
>
> Regards
> Nizham
>
> "Uri Dimant" wrote in message
>
>> Hi
>> Can you provide a little bit more about .BAK file? Does ot come from SQL
>> Server 2000 or SQL Server 2005?
>> It seems that .BAK file is corrupt. Have you dowloaded it from
>> anywhere?
>>
>>
>>
>>
>>
>>
>>
>> "Nizham" wrote in message
>>
>>> Hi
>>>
>>> OS Windows server 2003 SP1
>>> SQL Server 2005 Slandered Edition
>>>
>>> We try to restore the backup from the bak file and it is giving the
>>> following message
>>>
>>> System.Data.SqlClient.SqlError : Restore Detected an error on page (0:0)
>>> in database "Database_Name" as read from backup set
>>> (Microsoft.Sql.Server.Smo)
>>>
>>> Any one help me to solve this problem
>>>
>>> Regards
>>> Nizham
>>>
>>
>>
>
>
 >> Stay informed about: Database Restore Problem SQL Server 2005 
Back to top
Login to vote
Dan Guzman1

External


Since: Aug 22, 2004
Posts: 840



(Msg. 5) Posted: Mon Dec 04, 2006 10:45 am
Post subject: Re: Database Restore Problem SQL Server 2005 [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

I suggest you open a support case with Microsoft to see if they can help you
salvage data.

In the future, consider keeping backup files on a different server and also
a copy for offsite storage. It's also a good idea to regularly test your
restore process.

--
Hope this helps.

Dan Guzman
SQL Server MVP

"Nizham" wrote in message

> Hi
>
> Thanks for your imm response
>
> It is 2005 backup file. Actually what happen was the server hard disc was
> crashed and we recovered all the data there was are lot of bak files (Auto
> backup for last 1 month) . We tried all the files it is giving the same
> error message. We tried to attach the Database using sp_attach command
> by taking the mdf and ldf files it also giving error message.
>
> Will you please help us recover the data
>
> Regards
> Nizham
>
> "Uri Dimant" wrote in message
>
>> Hi
>> Can you provide a little bit more about .BAK file? Does ot come from SQL
>> Server 2000 or SQL Server 2005?
>> It seems that .BAK file is corrupt. Have you dowloaded it from
>> anywhere?
>>
>>
>>
>>
>>
>>
>>
>> "Nizham" wrote in message
>>
>>> Hi
>>>
>>> OS Windows server 2003 SP1
>>> SQL Server 2005 Slandered Edition
>>>
>>> We try to restore the backup from the bak file and it is giving the
>>> following message
>>>
>>> System.Data.SqlClient.SqlError : Restore Detected an error on page (0:0)
>>> in database "Database_Name" as read from backup set
>>> (Microsoft.Sql.Server.Smo)
>>>
>>> Any one help me to solve this problem
>>>
>>> Regards
>>> Nizham
>>>
>>
>>
>
>
 >> Stay informed about: Database Restore Problem SQL Server 2005 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Restore Sql Server 2005 db to Sql Server 2000 - I have a database that was backed up on a SQL Server 2005 system. Is it possible to restore the database to a SQL Server 2000 system?

Why doesn't sp_Depends show correct dependancies upon a da.. - I have recently restored a database from one MS SQL Server 2005 to another, and noticed that dependency information (sp_depends) is not showing dependencies for any of the Views/SP/UDF/triggers etc.... on the restored server/database (However all the....

Impossible to restore a sql express database with sql 2005.. - Hello, I have a big problem with a backup on sql 2005. I had SQL 2005 express studi and I bought SQL 2005 Workgroup Edition. I made a backup of my database with sql express and try to restore it with workgroup edition. But I can't. I have this message...

Connection String problem with SQL Server 2005 - Hello all I am pretty new to SQL Server 2005, having come from Access 2000. I have just purchased a copy of SQL Server 2005 Developers Edition and I am running through some examples in my SQL Server 7/VB6 book. In SQL Server 7 I could use the DSN-less....

SQL Server 2005 install problem - no Management Studio? - I just got through installing SQL Server 2005 Standard. Everything went fine, but now when I click Start. I see a few choices, but not Management Studio. Where did it go? Any thought on what I did wrong (or what I need to do in addition)? Thanks,..
   Database Help (Home) -> Programming All times are: Pacific Time (US & Canada)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]