July 17, 2003 at 7:12 am
trying to shrink trans log with dbcc shrinkfile getting:
Cannot shrink log file 2 (DirectoryLog) because all logical log files are in use.
July 17, 2003 at 7:17 am
Can you post your statement and result of sp_helpfile of your database? Which version od SQL Server you are running?
July 17, 2003 at 11:00 am
Where you running a log backup while trying to shrink the file?
July 18, 2003 at 4:10 am
Have u tried doing a
backup log <databasename> with truncate_only
first ?
July 18, 2003 at 6:40 am
Had this problem also. First do a complete backup, then set the database properties options - recovery to simple, then run the dbcc shrinkdatabase. Reset the recovery back to full.
regards,
July 18, 2003 at 10:35 am
Here's one I use:
USE master
BACKUP LOG Vision WITH NO_LOG
GO
Use MyDatabase
DBCC SHRINKFILE(MyDatabase_Log)
GO
July 21, 2003 at 8:00 am
When I receive that message, I back up the log two or three times in quick succession and then shrink the file.
July 24, 2003 at 1:35 pm
Create a test table in your database and do some dummy transactions in a loop. Then either shrink your log file or take a log backup with NO_LOG and take a full backup
Shas3
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply