Catalyzes the interconversion of L-serine and D-serine, and L-alanine and D-alanine. L-alanine is racemized at a rate that is 14% of that of L-serine. Necessary for vancomycin resistance in E.gallinarum. L-alanine = D-alanine L-serine = D-serine Amino-acid biosynthesis; D-alanine biosynthesis; D-alanine from L-alanine: step 1/1. Homodimer. The cytoplasmic C-terminal domain is responsible for the racemase activity. In the N-terminal section; belongs to the acyltransferase 3 family. In the C-terminal section; belongs to the alanine racemase family.