Cannot shrink log file 2 (sfs_genie_log) because all logical log files are in use.

i am trying to run the following command, but am getting an error:


DBCC SHRINKDATABASE (SFS_GENIE,10)


Cannot shrink log file 2 (sfs_genie_log) because all logical log files are in use.

How do I make the sfs_genie_log file not be in use? so that I can shrink it.

LVL 4
brokeMyLegBikingAsked:
Who is Participating?
 
SireesCommented:
To solve this temporarily change the Recovery Model to Simple.  You should then be able to shrink.
0
 
SweatCoderCommented:
In query analyzer, change the pull-down, active DB, from SFS_GENIE, to "master" or something.
0
 
brokeMyLegBikingAuthor Commented:
That didn't work. I ran a sp_who command to make sure that there are no open connections to the SFS_Genie database.

I also tried
dbcc shrinkfile( sfs_genie_log,1)
but that gave me the same message.
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
LowfatspreadCommented:
do you have replication active on the database?

are there uncommitted transactions?

have you tried adding a new log file?
0
 
brokeMyLegBikingAuthor Commented:
awesome, that worked. Thanks Sirees.
0
 
STEVE00098Commented:
Thank you
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.