Click here to Skip to main content
15,888,610 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
Hi
I have a database in SQL Server 2008 and being used in web hosting'

I noticed its log file is increased to 20 GB, so I am not sure how to remove the log file without affecting the system.

1. Can anybody tell me how to remove the log file or
2. Will it be beneficial if I just restrict Log size to 10 mb or somthing
3. can I restrict now it to 10 mb where it is already 20 gb file

Thanks in advance for your response

Bhaskar
[Link removed]
Posted
Updated 25-Nov-10 21:56pm
v3
Comments
Dalek Dave 26-Nov-10 3:56am    
Edited for Grammar.

Look at this thread[^]
 
Share this answer
 
Comments
Dalek Dave 26-Nov-10 3:56am    
Good link.
No i did not found the proper answer for my question..

EXEC SP_DBOPTION 'MYDBNAME', 'trunc. log. on chkpt', true


Bhaskar
 
Share this answer
 
You need to srink the log file.

Open SSME
Right click on database
click on Tasks >
Click on Srink >
click on Files >
choose file type as Log
and click ok
 
Share this answer
 
Comments
bhaskar_bhardwaj 30-Nov-10 2:18am    
do i need to do this everytime manually...or this can be automated..

Thanks
Bhaskar
<a href="http://www.brsolutions.info">B.R.Solutions</a>
RDBurmon 30-Nov-10 4:02am    
Did you know about SSIS ?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900