  Let $A$ be a unital commutative associative algebra over a field of
characteristic zero, $\k$ be a Lie algebra, and $\z$ a vector space, considered
as a trivial module of the Lie algebra $\g := A \otimes \k$. In this paper we
give a description of the cohomology space $H^2(\g,\z)$ in terms of well
accessible data associated to $A$ and $\k$. We also discuss the topological
situation, where $A$ and $\k$ are locally convex algebras.
