One-pot synthesis of lactams from cycloalkanes and tert-butyl nitrite by using N-hydroxyphthalimide as key catalyst.