Cell wall formation. [GlcNAc-(1->4)-Mur2Ac(oyl-L-Ala-gamma-D-Glu-L-Lys-D-Ala-D-Ala)](n)-di-trans,octa-cis-undecaprenyl diphosphate + beta-D-GlcNAc-(1->4)-Mur2Ac(oyl-L-Ala-gamma-D-Glu-L-Lys-D-Ala-D-Ala)-di-trans,octa-cis-undecaprenyl diphosphate = [GlcNAc-(1->4)-Mur2Ac(oyl-L-Ala-gamma-D-Glu-L-Lys-D-Ala-D-Ala)](n+1)-di-trans-octa-cis-undecaprenyl diphosphate + di-trans,octa-cis-undecaprenyl diphosphate + H(+) Preferential cleavage: (Ac)2-L-Lys-D-Ala-|-D-Ala. Also transpeptidation of peptidyl-alanyl moieties that are N-acyl substituents of D-alanine. Cell wall biogenesis; peptidoglycan biosynthesis. Interacts with MreC in the elongasome. Not essential, it can be deleted. In the N-terminal section; belongs to the glycosyltransferase 51 family. In the C-terminal section; belongs to the transpeptidase family.