Friday, February 24, 2012

Cannot shrink transaction log - windows 2003/sp1 and SQL 2000/SP4

I cannot shrink a transaction log to a database through the enterprise mmc.
This particular transaction log is about 135 GB and is filling up the hard
drive. Is there a way to force this?http://support.microsoft.com/kb/q272318/
--
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Sabo, Eric" wrote:
> I cannot shrink a transaction log to a database through the enterprise mmc.
> This particular transaction log is about 135 GB and is filling up the hard
> drive. Is there a way to force this?|||Mike,
Thanks for the reply but where do you run this command from. Also, what
if I have no space to backup this transaction log.
"Mike Epprecht (SQL MVP)" wrote:
> http://support.microsoft.com/kb/q272318/
> --
> --
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
> MVP Program: http://www.microsoft.com/mvp
> Blog: http://www.msmvps.com/epprecht/
>
> "Sabo, Eric" wrote:
> > I cannot shrink a transaction log to a database through the enterprise mmc.
> > This particular transaction log is about 135 GB and is filling up the hard
> > drive. Is there a way to force this?|||It is saying the following when I tried to shrink the database:
Cannot shrink log file 2 (XXXXXXXX_log) because all logical log files are in
use.
"Sabo, Eric" wrote:
> I cannot shrink a transaction log to a database through the enterprise mmc.
> This particular transaction log is about 135 GB and is filling up the hard
> drive. Is there a way to force this?|||Hi
OK, so I assume that you have not backuped up your transaction log, nor
require it, so put the DB in simple Recovery Mode using Enterprise Manager
(Property of the DB)
This will clear all inactive entries in the log and then you can shrink the
log,
You need to run those commands in the KB from Query Analyser.
Look up "recovery plan" in Books Online to understand how the log is used
for recovery in DR scenarios.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Sabo, Eric" wrote:
> Mike,
> Thanks for the reply but where do you run this command from. Also, what
> if I have no space to backup this transaction log.
> "Mike Epprecht (SQL MVP)" wrote:
> > http://support.microsoft.com/kb/q272318/
> > --
> > --
> > Mike Epprecht, Microsoft SQL Server MVP
> > Zurich, Switzerland
> >
> > MVP Program: http://www.microsoft.com/mvp
> >
> > Blog: http://www.msmvps.com/epprecht/
> >
> >
> >
> > "Sabo, Eric" wrote:
> >
> > > I cannot shrink a transaction log to a database through the enterprise mmc.
> > > This particular transaction log is about 135 GB and is filling up the hard
> > > drive. Is there a way to force this?|||Mike,
Thanks alot.
That worked. I restricted the growth this time so it will not fill up my
hard drive again. Thanks again!
"Mike Epprecht (SQL MVP)" wrote:
> Hi
> OK, so I assume that you have not backuped up your transaction log, nor
> require it, so put the DB in simple Recovery Mode using Enterprise Manager
> (Property of the DB)
> This will clear all inactive entries in the log and then you can shrink the
> log,
> You need to run those commands in the KB from Query Analyser.
> Look up "recovery plan" in Books Online to understand how the log is used
> for recovery in DR scenarios.
> Regards
> --
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
> MVP Program: http://www.microsoft.com/mvp
> Blog: http://www.msmvps.com/epprecht/
>
> "Sabo, Eric" wrote:
> > Mike,
> >
> > Thanks for the reply but where do you run this command from. Also, what
> > if I have no space to backup this transaction log.
> >
> > "Mike Epprecht (SQL MVP)" wrote:
> >
> > > http://support.microsoft.com/kb/q272318/
> > > --
> > > --
> > > Mike Epprecht, Microsoft SQL Server MVP
> > > Zurich, Switzerland
> > >
> > > MVP Program: http://www.microsoft.com/mvp
> > >
> > > Blog: http://www.msmvps.com/epprecht/
> > >
> > >
> > >
> > > "Sabo, Eric" wrote:
> > >
> > > > I cannot shrink a transaction log to a database through the enterprise mmc.
> > > > This particular transaction log is about 135 GB and is filling up the hard
> > > > drive. Is there a way to force this?

No comments:

Post a Comment