"Your eyes can deceive you; don't trust them." Obi-Wan instructs Luke in Star Wars: Episode IV – A New Hope. "Wax on. Wax off." Mr. Miyagi prepares Daniel in The Karate Kid. "Free your mind." Morpheus enlightens Neo in The Matrix. All advice, all from mentors, all with the belief in his student's exceptional ability, and without that, the hero surely will fail. Imagine Frodo without Gandalf (The Lord of the Rings). The little hobbit, despite all his wits, would have no chance.
The mentor is a supporting character and the hero's most experienced and trusted advisor, who helps guide the hero, aiding him or her to obtain the protagonist's objective. He has been through what the hero is going through, maybe many times, and he has succeeded and possibly failed in the past, but he is too old to go through it again alone, or the task at hand is bigger than anything he's taken on before, and our hero has more potential than the mentor ever did.
Essentially, the mentor is a coach, and the hero is his highly talented but undisciplined student. The mentor has the power to help the hero avoid problems and pitfalls along the way, but often the hero won't listen, or the mentor sees the greater wisdom in allowing the hero to figure things out on his or her own.
Most mentors are positive guides for the hero; however, mentors can also create conflict for the hero by getting jealous, refusing to help, withholding information, giving wrong information, resenting the hero, or compromising the mission.
Fortunately for Luke, that was not the case with Obi-Wan: "The Force will be with you, always."