Cleaves the C-terminal D-alanine residue of UDP-muramyl-pentapeptide (UDP-MurNAc-L-Ala-D-Glu-mDAP-D-Ala-D-Ala) (PubMed:1510448). However the physiological substrate likely contains L-Lys instead of mDAP at the third position of the pentapeptide (Probable). Also releases the C-terminal D-lactate from UDP-MurNAc-L-Ala-D-Glu-mDAP-D-Ala-D-lactate, a depsipeptide produced by the vancomycin resistance protein VanA. Therefore, VanY should contribute in vivo to the hydrolysis of both the D-alanyl-D-alanine- and the depsipeptide-containing peptidoglycan precursors (PubMed:1510448). Is not necessary for vancomycin resistance of E.faecium BM4147 (PubMed:1398115). Does not display transpeptidase or beta-lactamase activities (PubMed:1510448). The DD-carboxypeptidase activity is not inhibited by beta-lactam antibiotics. By vancomycin. Part of the van gene cluster of pIP816, the plasmid that confers high-level resistance to vancomycin in E.faecium BM4147. Belongs to the peptidase M15B family.