The present invention provides a method for identifying or generating an attenuated mycoplasma bacterium, which bacterium comprises a mutation in at least one gene as listed and use of the bacterium in a vaccine for eliciting protective immunity against mycoplasma or for detecting infection by said bacterium.