[PM-18504] Enable SQL transaction log backup #5433
Open
+15
โ1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello,
๐๏ธ Tracking
bwdata/mssql/data/vault_log.ldf
, which is the SQL transaction log file, grows indefinitely.๐ Objective
This PR then adds the transaction log backup to the full backup, so that it is properly rotated, preventing it to grow.
It then fixes #648, with a better / safer approach than #3140.
๐ฆฎ User guidelines
If one wants to shrink the transaction log file, which may have grown unexpectedly (because not backed-up until now), the following SQL command will be needed (after 2 backups at least so that the end of the transaction log gets unused) :
use vault;
go
DBCC SHRINKFILE (vault_log);
go
It has not been added as a command to the backup script, as it is not considered as a regular maintenance one, but added a a guideline.
Thank you very much ๐