A disgraced dentist has admitted charges linked to a massive cannabis factory.