monarchit
asked on
SQL 2005 transaction log
Hi,
I have a SQL 2005 cluster server running 32 bit. I have a database roughly around the size of 520gb. The transcation log is currently sitting at 72GB. I have a full backup that runs daily which is supposed to truncate the logs files? It appears this transcation log is not shrinking.
What can i do to solve this and it is effecting performance.
Regards
I have a SQL 2005 cluster server running 32 bit. I have a database roughly around the size of 520gb. The transcation log is currently sitting at 72GB. I have a full backup that runs daily which is supposed to truncate the logs files? It appears this transcation log is not shrinking.
What can i do to solve this and it is effecting performance.
Regards
Backing up, and truncating the logs doesn't cause them to shrink, it allows the space to be reused.
The best practice recommendation is also to NOT shrink the transaction logs, unless you know something very unusual has occurred to cause them to grow much larger than they need to be.
The best practice recommendation is also to NOT shrink the transaction logs, unless you know something very unusual has occurred to cause them to grow much larger than they need to be.
One key way to stop it from growing too much is to change the recovery type to:
"Simple recovery model" in the SQL Settings
Just make sure that the recovery model you select meets your recovery needs.
"Simple recovery model" in the SQL Settings
Just make sure that the recovery model you select meets your recovery needs.
If you don't need to take transaction log backups, just switch the database to Simple Recovery Model and shrink the log file manually, using Tasks > Srink > Files on the database.
If you don't need the point in time recovery... I concur with Gene_Cyp and graf0 -- Simple Recovery Model might be a good fit for you.
I feel I should mention however -- one of the mistakes I made when starting with SQL was to assume the Transaction Log in the Simple Recovery Model was either minimally used or not used. Be aware that the Transaction Log still needs to be sized sufficient to hold entire transactions while they are being committed to the database. It won't be 'nothing' and probably won't be just the size of a single transaction... but it will probably be smaller than your transaction log will want to be with the Full Recovery Model.
One of the worst things you can do for performance would be to go through repeated cycles of shrinking and growing your transaction log files...
I feel I should mention however -- one of the mistakes I made when starting with SQL was to assume the Transaction Log in the Simple Recovery Model was either minimally used or not used. Be aware that the Transaction Log still needs to be sized sufficient to hold entire transactions while they are being committed to the database. It won't be 'nothing' and probably won't be just the size of a single transaction... but it will probably be smaller than your transaction log will want to be with the Full Recovery Model.
One of the worst things you can do for performance would be to go through repeated cycles of shrinking and growing your transaction log files...
Hi,
First take back off Log file and truncate it.
First take back off Log file and truncate it.
most of the guys have answered to u r question.
I would like to know how frequent u r taking the t-log backups, for example if u r taking t-log backup every 1 hr then change it to 30 min.. and see. if you don't want point in time recovery then u r set it to simple recovery model.
I would like to know how frequent u r taking the t-log backups, for example if u r taking t-log backup every 1 hr then change it to 30 min.. and see. if you don't want point in time recovery then u r set it to simple recovery model.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thanks
Don't worry they are all brief:
http://support.microsoft.com/kb/873235
http://support.microsoft.com/kb/110139
http://www.databasedesign-resource.com/sql-server-transaction-log.html