The inelastic cross sections and rate coefficients for the rotational excitation of methanimine (CH2NH) by cold H2 have been determined quantum mechanically based on a new highly correlated five-dimensional potential energy surface. This surface was fitted to more than 60 000 ab initio points with a root mean square error of ∼ 1-2 cm−1 in the region of the potential well whose depth is -374.0 cm−1. The rotationally inelastic rate coefficients have been combined with spectroscopic data to generate the non-equilibrium spectrum of CH2NH towards the interstellar molecular cloud Sgr~B2(N). The transition 110→111 at 5.29 GHz is found to be inverted and the predicted weak maser emission spectrum is in excellent agreement with new observations performed with the 100-meter Green Bank Telescope.