Tuesday, February 14, 2012

Database crashed its very urgent

Hi All,
one of my database is suddenly crashed with power fluctuation and when i
started the server it is showing "not able to connect database". I have taken
backup and i was trying to attach database in other system. It has given me
the following error.
Microsoft SQL-DMO (ODBC SQLState: HY000)
Error 9003: The LSN (375:9588:1) passed to log scan in database
'QVLMSCASPARES' is invalid.
OK
Please any one can help me out.
With Regards,
AHARI
Srihari wrote:
> Hi All,
> one of my database is suddenly crashed with power fluctuation and
> when i started the server it is showing "not able to connect
> database". I have taken backup and i was trying to attach database in
> other system. It has given me the following error.
> --
> Microsoft SQL-DMO (ODBC SQLState: HY000)
> --
> Error 9003: The LSN (375:9588:1) passed to log scan in database
> 'QVLMSCASPARES' is invalid.
What do you mean by "I have taken backup"? Do you mean you took a copy
of the database file(s) from the original server when SQL Server was
either off-line or the database was detached. Or do you mean you
performed a backup using BACKUP DATABASE? If you are trying to restore a
backup, then use RESTORE DATABASE. If you are using a copy of the
database files and log files, then use sp_attach_db or
sp_attach_single_file_db.
See if this helps.
http://support.microsoft.com/kb/328354
David Gugick
Quest Software
www.imceda.com
www.quest.com
|||I have taken files offline and trying to attach in other system.
With Regards,
AHARI
"David Gugick" wrote:

> Srihari wrote:
>
> What do you mean by "I have taken backup"? Do you mean you took a copy
> of the database file(s) from the original server when SQL Server was
> either off-line or the database was detached. Or do you mean you
> performed a backup using BACKUP DATABASE? If you are trying to restore a
> backup, then use RESTORE DATABASE. If you are using a copy of the
> database files and log files, then use sp_attach_db or
> sp_attach_single_file_db.
> See if this helps.
> http://support.microsoft.com/kb/328354
>
> --
> David Gugick
> Quest Software
> www.imceda.com
> www.quest.com
>
|||Srihari wrote:
> I have taken files offline and trying to attach in other system.
> With Regards,
> AHARI
>
According to BOL:
"sp_attach_db should only be executed on databases that were previously
detached from the database server using an explicit sp_detach_db
operation. If more than 16 files must be specified, use CREATE DATABASE
with the FOR ATTACH clause.
If you attach a database to a server other than the server from which
the database was detached, and the detached database was enabled for
replication, you should run sp_removedbreplication to remove replication
from the database."
I'm not sure what will happen if you try to attach a copy of the
database files without first using the detach function. Are you
attaching the log files as well? If so, have to tried to not attach the
log file.
See if using the CREATE DATABASE with the FOR ATTACH clause works
instead:
http://support.microsoft.com/?kbid=885712
David Gugick
Quest Software
www.imceda.com
www.quest.com

No comments:

Post a Comment