If $X$ has a universal cover $\widetilde{X}$, then $\widetilde X$ is a prinicpal $\pi_1(X)$-bundle over $X$. Suppose $$ A \to E \to \pi_1(X) $$ is a central extension. Then, the corresponding class in $H^2(X,A)$ is the obstruction against a lift of the structure group of $\widetilde X$ from $\pi_1(X)$ to $E$.
To see this, suppose $\widetilde X$ has transition functions $g_{\alpha\beta}:U_{\alpha}\cap U_{\beta} \to \pi_1(X)$. If the open sets are small enough, they can always be lifted to $E$, but theythe lifts won't satisfy the cocycle condition. The error in the cocycle formula makes up a 3-cocycle $h_{\alpha\beta\gamma}: U_{\alpha}\cap U_{\beta} \cap U_{\gamma} \to A$.
Now, $h_{\alpha\beta\gamma}$ quite obviously represents the obstruction class in $H^2(X,A)$. On the other hand, above procedure takes, on the level of classifying maps, the composite $$ X \to B\pi_1(X) \to BBA $$ with the homotopy fibre of the central extension. And this (I assume) is your "well-known" map.
The obstruction class can also be represented by a bundle gerbe, the so-called lifting bundle gerbe. The lifting bundle gerbe is a general thing: it represents the obstruction class for lifting the structure group of a bundle along a central extension.
Here, it has structure group (or band, if you like) $A$. It is constructed with the fibration $\widetilde X \to X$, and over the fibre product $\widetilde X \times_X \widetilde X$ its "transition bundle" is the pullback of $E \to \pi_1(X)$ along the difference map $$ \delta: \widetilde X \times_X \widetilde X \to \pi_1(X). $$ Bundle gerbes with structure group $A$ have characteristic classclasses in $H^2(X,A)$, and it is a little exercise to check that the class of the lifting gerbe is the obstruction to solving the lifting problem.