Re: Droping suspect publication database

From: Esio Nunes (esio_nunes_at_hotmail.com)
Date: 11/24/04


Date: Wed, 24 Nov 2004 09:47:23 -0300

I tryied this but the problem is with the data file, not log file.

Ésio

"Adrian Mos" <AdrianMos@discussions.microsoft.com> escreveu na mensagem
news:3EF556B1-B7A2-4CC8-B461-7093574C68F3@microsoft.com...
> 1. Put the db into EMERGENCY BYPASS STATUS (32768)
> -- so you can rebuild the log
> sp_configure 'allow', 1
> go
> reconfigure with override
>
> update sysdatabases
> set status = -32768
> where name='yourDBname'
>
> 2. Stop sql server - rename log file (You will delete
> it later)
>
> 3. Start sql server. Rebuild the log.
>
> dbcc rebuild_log
> ('yourDBname', 'TheDriveForLogFiles:\PathToLogFiles\logfilename.ldf')
>
> 3. Put db back from EMERGENCY BYPASS STATUS (32768) to
> status 16
>
> update sysdatabases
> set status = 16 -- or 24
> where 'yourDBname'
>
> 4. Clean up
> sp_configure 'allow', 0
> go
> reconfigure with override
>
>
>
> Now you have solved the most probable cause of your 'Suspect' status: a
> corrupted log file. After this you have a clean log file and SQL will be
able
> to start the DB not heaving to roll back or forward corrupted
transactions.
> Then you can run DBCC CheckDB to see if the data file is OK or you can
drop
> the database as you wish.



Relevant Pages

  • Re: Droping suspect publication database
    ... reconfigure with override ... Stop sql server - rename log file (You will delete ...
    (microsoft.public.sqlserver.replication)
  • Re: VSFTP question
    ... # Activate logging of uploads/downloads. ... # You may override where the log file goes if you like. ... Shiva wrote: ...
    (linux.redhat)
  • How can I read a locked VMS file?
    ... I have a log file that is locked. ... is production critical; I cannot terminate it. ... Is there a way to override the ... VMS file lock in order to view the contents of this file? ...
    (comp.os.vms)