cancel
Showing results for 
Search instead for 
Did you mean: 

How to Clear the Archive-Log in SQL 2005 ?

Former Member
0 Kudos

Hi Expert!!

I am using MS-SQL 2005 on 64 bit processor.

I have been stuck in the "transacation log for database 'PRD' is full. To find out why space cannot be reused, see the log_reuse_wait_desc column in sys.databases"

My log disk was 30GB in Production, here recommendation required , how to clear the archive log automatically.

Regards

Anwer Waseem

SAP BASIS

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member193399
Active Participant
0 Kudos

You have to perform these steps during the down time:

1) Take a full backup of your production database.

2) execute query

DBCC SHRINKFILE (<logical file name of the log file> , 0, TRUNCATEONLY) 

To find the logical file name:

sp_helpdb <db_name of >

alternative you use enterprise manager to shrink file.

right click database->tasks->shrink->file

a dialog box appreas. Select the "File type" as log. You all set.

WARNING: Make sure you take a full backup of the database before this step!

I hope this helps...