Transaction Log Becoming Full Due To Replication

in #data3 years ago

Review the solution and discussion in the video The transaction log for database 'DB' is full due to 'REPLICATION'. We do not want to develop the habit of micro-managing transaction logs, so we should consider sizing before setting up any architecture such as replication, ETL solutions, etc. As a note that's not mentioned in the video: since transactional replication uses the log and involves full recovery, we cannot switch to simple recovery without first disabling replication. Thus, we must be in a situation where we can make log adjustments if we cannot disable replication.

Consider these in the context of the video:

  • What is something we should avoid with the log?
  • Why is development around the log so important?
  • Considering that this is an error we can face, what are some architecture considerations regarding the log when we're replicating data?

Automating ETL
Check out the highest-rated Automating ETL course on Udemy, if you're interested in data.

In general, everything in a database relies around the log. For this reason, we want to consider how we plan for log growth from when we first create our database. If we do not make these plans appropriate, we'll run into a myriad of problems involving the log. Our log growth will also dictate that type of transactions that we allow.

One regular point I like to remind my audience, especially as of recent: we can often solve the same problem with a variety of techniques. While we look at one or two ways to solve the problem, these aren't the only ways we can approach this problem. The most appropriate solution to a problem is one in which you can troubleshoot quickly in the future and one in which you understand. Be careful about applying solutions that solve a problem, but introduce new problems in the future.

A great re-occuring example of this is my discussion on alerting best practices. There are a variety of alerts everywhere for everything in today's development environments, but many of these alerts cause more issues than they solve (one of which is creating a distraction). Be careful about "easy" solutions which introduce bigger problems. Know your environment and where to apply the best solution. Of course, all these being written, it is helpful to learn new techniques to solve problems because they may be useful in the future.

YouTube | Automating ETL | T-SQL In 2 Hours | Consumer Guide To Digital Security