Step 1: Use substitution.
Let \(x + 1 = t^2\). Then
\[
dx = 2t\,dt, \quad x + 2 = t^2 + 1
\]
Step 2: Substitute into the integral.
\[
\int \frac{dx}{(x+2)\sqrt{x+1}}
= \int \frac{2t\,dt}{(t^2+1)t}
= \int \frac{2}{t^2+1}\,dt
\]
Step 3: Integrate.
\[
= 2\tan^{-1} t + c
\]
Step 4: Substitute back.
\[
= 2\tan^{-1}(\sqrt{x+1}) + c
\]