Answer
\[\frac{1}{(b-a)}\ln\left|\frac{x+a}{x+b}\right|+C\]
Where $C$ is constant of integration
Work Step by Step
Let \[I=\int \frac{1}{(x+a)(x+b)}dx\]
Partial fraction decomposition of integrand is given by
\[\frac{1}{(x+a)(x+b)}=\frac{A}{(x+a)}+\frac{B}{(x+b)}\]
\[\Rightarrow 1=A(x+b)+B(x+a)\]
\[\Rightarrow 1=(aB+bA)+x(A+B)\]
Compare like coefficients
\[A+B=0\Rightarrow B=-A\;\;\;...(1)\]
and \[aB+bA=1\]
Using (1)
\[A(b-a)=1\Rightarrow A=\frac{1}{b-a}\]
From (1)
\[B=\frac{-1}{b-a}\]
\[\Rightarrow \frac{1}{(x+a)(x+b)} =\frac{1}{b-a}\left[\frac{1}{x+a}-\frac{1}{x+b}\right]\]
\[I=\frac{1}{b-a}\int \left[\frac{1}{x+a}-\frac{1}{x+b}\right]dx\]
\[\Rightarrow I=\frac{1}{b-a}[\ln |x+a|-\ln |x+b|]+C\]
Where $C$ is constant of integration
\[\Rightarrow I=\frac{1}{b-a}\ln\left|\frac{x+a}{x+b}\right|+C\]
Hence, \[\int \frac{1}{(x+a)(x+b)}dx=\frac{1}{b-a}\ln\left|\frac{x+a}{x+b}\right|+C\]