One way to attack improper integrals of the form
$$\int_0^{\infty} dx \, f(x) $$
is to use the residue theorem, i.e. contour integration in the complex plane. To do this, one considers the contour integral
$$\oint_C dz \, f(z) \log{z} $$
where $C$ is a keyhole contour about the positive real axis, of inner radius $\epsilon$ and outer radius $R$. We consider the limits as $\epsilon \to 0$ and $R \to \infty$. In most cases, the integrals about the inner and outer circles vanish in these limits (I will not prove here).
In this case, our statement of the residue theorem takes the form
$$\int_0^{\infty} dx \frac{\log^2{x} - (\log{x}+i 2 \pi)^2}{x^2+2 x+4} = i 2 \pi \sum_{k=1}^2\frac{\log^2{z_k}}{2 z_k+2}$$
where $z_{1,2}= -1 \pm i \sqrt{3}$, or, in other words, $z_1 = 2 e^{i 2 \pi/3}$ and $z_2=2 e^{i 4 \pi/3}$. Note that the arguments of the $z_k$ are between $[0,2 \pi]$ necessarily because of how $C$ was defined. Thus,
$$-i 4 \pi \int_0^{\infty} dx \frac{\log{x}}{x^2+2 x+4} + 4 \pi^2 \int_0^{\infty} dx \frac{1}{x^2+2 x+4} = i 2 \pi \left [\frac{(\log{2} + i 2 \pi/3)^2}{i 2 \sqrt{3}} + \frac{(\log{2} + i 4 \pi/3)^2}{-i 2 \sqrt{3}} \right ]$$
Equating real and imaginary parts, we find that
$$\int_0^{\infty} dx \frac{1}{x^2+2 x+4} = \frac{\pi}{\sqrt{3}} $$
$$\int_0^{\infty} dx \frac{\log{x}}{x^2+2 x+4} = \frac{\pi}{ 3 \sqrt{3}} \log{2}$$