On a problem of magnetohydrodynamics in a multi-connected domain