Catalyzes the NAD(+)-dependent oxidation of L-carnitine to 3-dehydrocarnitine. Despite a high similarity to 3-hydroxyacyl-CoA dehydrogenases, cannot dehydrogenate 3-hydroxybutylate and 3-hydroxybutyl-CoA. Is probably involved in a L-carnitine degradation pathway that allows Rhizobium sp. YS-240 to grow on L-carnitine as the sole source of carbon and nitrogen. carnitine + NAD(+) = 3-dehydrocarnitine + H(+) + NADH Amine and polyamine metabolism; carnitine metabolism. Homodimer. In the N-terminal section; belongs to the 3-hydroxyacyl-CoA dehydrogenase family. L-carnitine dehydrogenase subfamily.