Notice that I scaled the y value of geom_col up by the same factor that I reduced the value in sec_axis().
library(ggplot2)
tmp6 <- data.frame(Month = c(1,1,2,2,3,3,4,4),
Teams = c("A", "B", "A", "B", "A", "B", "A", "B"),
Total = c(1000, 1200, 1150, 1220, 1300, 1030, 1060, 1380),
Failed = c(6,4,7,8,2,6,9,4))
ggplot(data = tmp6,aes(x=Month, y=Total,group = Teams)) +
geom_line(aes(color = Teams),size = 1)+
geom_col(aes(x=Month,y=Failed * 100, fill=Teams), position = "dodge") +
scale_y_continuous(sec.axis = sec_axis(trans = ~ . /100, name="Failed (bars)"))+
labs(x = "Month", y = "Total (lines)")

Created on 2020-08-06 by the reprex package (v0.3.0)