[导入]Shrink large database log files on our development server
Even though we have a 300GB hard disk, it is running out of space when we host more and more development databases. This morning one of my program failed because its back end database log file had reached the upper limit.
All my attempt faield as recorded as following,
1. Delete the log files directly
2. Add another log file and then try to delete the primary log file
3. Detach the database, delete those log files, then tried to attach the MDF file. It failed because MS refused to attach it when certain files are missing.
In the end I changed the recovery mode of the database to Simple instead of Full as this is a development server we don't need to restore it to the point of failure, lots of space were reclaimed.
文章来源:http://zouyu.blogspot.com/2006/03/shrink-large-database-log-files-on-our.html
All my attempt faield as recorded as following,
1. Delete the log files directly
2. Add another log file and then try to delete the primary log file
3. Detach the database, delete those log files, then tried to attach the MDF file. It failed because MS refused to attach it when certain files are missing.
In the end I changed the recovery mode of the database to Simple instead of Full as this is a development server we don't need to restore it to the point of failure, lots of space were reclaimed.
文章来源:http://zouyu.blogspot.com/2006/03/shrink-large-database-log-files-on-our.html