Let me expand a little bit my previous comment. For the sake of simplicity, I will assume first that $D$ is smooth.
Then one has a short exact sequence
$0 \to T_X(- \log D) \to T_X \to N_{D|X} \to 0 \quad (*)$,
where $T_X(- \log D)$ is the sheaf of tangent vectors on $X$ which are tangent to $D$. The group $H^1(X, T_X(\log D)$ classifies the first-order deformations of the pair $(X, D)$, and the obstructions lie in $H^2(X, T_X(-\log D))$.
Taking cohomology in $(*)$, we obtain
$H^0(D, N_{X|D}) \stackrel{\alpha}{\to} H^1(X, T_X(-\log D)) \to H^1(X, T_X) \stackrel{\beta}{\to} H^1(D, N_{D|X}) \to H^2(X, T_X(-\log D)).$
It is well known that the group $H^0(D, N_{D|X})$ classifies first-order embedded deformations of $D$ in $X$, with $X$ fixed. Therefore the map $\alpha$ naturally associates to every such a deformation the corresponding deformation of the pair $(X, D)$.
Moreover, we can interpret the map $\beta$ as the obstruction to lifting an abstract first-order deformation of $X$ to a deformation of the pair $(X, D)$.
For instance, let $X$ be a smooth projective surface and $D$ a nonsingular rational curve with
$D^2=-1$. Then $H^1(D, N_{D|X})=0$, so every abstract deformation of $X$ lifts to a deformation of the pair $(X, D)$.
If instead $D^2=-2$, there are in general abstract deformations of $X$ which do not come from deformations of the pair. For example, the general deformation of a Kummer surface (which contain 16 $(-2)$-curves) is a $K3$ surface without $(-2)$-curves.
When $D$ is singular, the same arguments hold with $N_{D|X}$ replaced by the so-called equisingular normal sheaf $N'_{D|X}$. See Sernesi's book [Deformation of algebraic schemes, Chapter 3] for further details.