|
Home > Archive > MS SQL Server > November 2005 > Transaction Log
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Wolfgang 2005-11-29, 7:23 am |
| Hi all,
I have a 10GB database with 65GB Transaction Log. The Transaction Log
is too big and causes problems doing backups.
I tried to reduce the log size using Enterprise Manager as well as dbcc
shrinkfile. I also used dbcc shrinkdatabase. But the size of the log
does not change.
Any idea, how I can reduce the log to a reasonable size?
Thanks
Wolfgang
| |
| Uri Dimant 2005-11-29, 7:23 am |
| Hi
It's time to start BACKUPing LOG file , otherwise database's recovery mode
to SIMPLE
For more info please refer to BOL or search on intrenet
"Wolfgang" <Wolfgang. Schumacher@bowebellh
owell.de> wrote in message
news:1133260624.023192.160310@f14g2000cwb.googlegroups.com...
> Hi all,
>
> I have a 10GB database with 65GB Transaction Log. The Transaction Log
> is too big and causes problems doing backups.
> I tried to reduce the log size using Enterprise Manager as well as dbcc
> shrinkfile. I also used dbcc shrinkdatabase. But the size of the log
> does not change.
> Any idea, how I can reduce the log to a reasonable size?
>
> Thanks
> Wolfgang
>
| |
| Steen Persson (DK) 2005-11-29, 7:23 am |
| Wolfgang wrote:
> Hi all,
>
> I have a 10GB database with 65GB Transaction Log. The Transaction Log
> is too big and causes problems doing backups.
> I tried to reduce the log size using Enterprise Manager as well as dbcc
> shrinkfile. I also used dbcc shrinkdatabase. But the size of the log
> does not change.
> Any idea, how I can reduce the log to a reasonable size?
>
> Thanks
> Wolfgang
>
Hi Wolfgang
You might need to backup your log before you can shrink it.
The steps is :
1. run BACKUP LOG xxxxxx (if you don't need/use the log backup you can
run it with the NO_LOG option)
2. run DBCC SHRINKFILE (YourLogicalFileName
, target_size)
You can look up more details about the commands in Books On Line. Please
also remember that DBCC SHRINKDATABASE is different from DBCC
SHRINKFILE. SHRINKDATABASE will shrink all data and log files in the
database. This will most likely take quite a while since it will also
shrink your datafile and that's not always a good idea.
DBCC SHRIKNFILE (logicalfilename, size) will only shrink the file you
specify as logicalfilename and is in most case much faster.
Remember that when you run DBCC SHRINKFILE, you need to be in the
database you're shrinking.
Regards
Steen
| |
| Bud Y. Zer 2005-11-29, 8:23 pm |
| Use GOOGLE. This question has been posted a million (milliard) times
before!
"Wolfgang" <Wolfgang. Schumacher@bowebellh
owell.de> wrote in message
news:1133260624.023192.160310@f14g2000cwb.googlegroups.com...
> Hi all,
>
> I have a 10GB database with 65GB Transaction Log. The Transaction Log
> is too big and causes problems doing backups.
> I tried to reduce the log size using Enterprise Manager as well as dbcc
> shrinkfile. I also used dbcc shrinkdatabase. But the size of the log
> does not change.
> Any idea, how I can reduce the log to a reasonable size?
>
> Thanks
> Wolfgang
>
|
|
|
|
|