Tuesday, March 20, 2012

Bigger log file a database

I have a database, the log file is very long (1 gb)
how to do to reduce the log file?
thank
Check in SEM, to see if your database is in full recovery mode... If so,
Backup the transaction log
ie
Backup log prod to disk="c:\lkjlklj.log" with init
then (until it shrinks) in Query Analyzer
Use prod
go
DBCC Shrinkfile (logfilename, neededsizeinMB)
GO
If the database is in simple recovery mode, just do the shrink
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"alexander" <alexander@.discussions.microsoft.com> wrote in message
news:8B1EF531-933E-4422-90D9-FFC040F2E2CF@.microsoft.com...
> I have a database, the log file is very long (1 gb)
> how to do to reduce the log file?
>
> thank

No comments:

Post a Comment