How do you know your dog has ear mites? They can only bee seen under a microscope. Have you been to a vet, have they diagnosed it?
Those could also just be signs of an ear infection with yeast or bacteria. Since Ivermectin is NOT safe for all dogs, do NOT decide to give it on your own. Have the vet see if it's an infection or mites and get appropriate treatment.