Devotion is the head of mediation.

Faith in one’s guru does not mean blind faith, it does not mean believing “My guru is perfect” even though your guru is not perfect. It is not pretending that your guru’s defects are qualities. It is not rationalizing every foible of the guru into a superhuman virtue. After all, most gurus will have defects. You need to recognize them for what they are. You don’t have to pretend your guru’s defects are qualities, because the object of your devotion is not the foibles, quirks, or defects of your guru, but the Dharma that your guru is teaching you. You are not practicing the guru’s foibles. As long as the Dharma you receive is authentic and pure, then the guru is a fit object for your devotion. You need to recognize the defects of your guru as defects- you don’t need to pretend they are otherwise. The guru’s defects cannot hurt you, because it is not they that you create or cultivate. You follow the teaching of the guru, and “trust” meaning trust in the validity of the teachings themselves.

Venerable Thrangu Rinpoche, in commentary on Creation and Completion by Jamgon Kongtrul the Great

This is an article by Lama Kathy Wesley on choosing a teacher in dharma practice.

Here, Lama Ken McLeod writes about the student/teacher relationship.

Here is the Shambhala Magazine Student Teacher Relationship ‘Further Reading List