From the Manners of Knowledge
The Etiquettes of a Student of Knowledge
* The student of knowledge must first know that Allaah has made it obligatory for him to worship Him, and worship cannot be attained except through knowledge. And he must know that it is not befitting for a Muslim to remain in ignorance. Thus, his search for knowledge is so that he may eradicate ignorance from himself and so that he may worship his Lord in the manner in which Allaah has commanded, not in the manner in which his desires deem appropriate. This should be his intention in his efforts for seeking knowledge, such that he has sincerity instilled in his heart, with regard to his exertion. He must not see any merit in his efforts, as belonging to himself, but rather he must see that all of the merit placed upon him, belongs to Allaah. This is because, with seeking knowledge, Allaah has granted him the means by which he may worship Him properly, by way of performing the obligations and abstaining from the prohibitions.
* He must avoid all affairs that cause him to draw his attention away from the objective (of knowledge), except for those things which he must involve himself with for needs sake. Allaah says: "Allaah has not placed two hearts in the body of a man." [Surat-ul-Ahzaab: 3] And most importantly, whenever ones thoughts are divided, he is hindered from achieving the realization of his objectives. For this reason, it is said: "Knowledge will not give you part of itself, until you first give it all of yourself."
* He must also begin by cleansing his soul from reprehensible manners and reprehensible characteristics. This is since knowledge is an act of worship of the heart as well as a hidden link and concealed means of drawing nearer to Allaah. Thus in the same way that prayer, which is a duty upon the visible body’s limbs, is not valid, except by performing visible purification over the filth and uncleanness, hidden acts of worship as well as rectifying the heart with knowledge is not valid, except after purifying it from filthy manners and unclean characteristics. For this reason it is said: "The heart is purified through knowledge, just as the land is purified though tilling."
* He must not feel proud or arrogant about the knowledge he acquires. Rather, he must display humility in front of his teacher and grant him full control to direct and supervise him in all matters. He should submit himself willingly in the same way that a sick person, that is ignorant about medicine, submits himself to a concerned and proficient doctor. And if his teacher should be younger than him in age and possess little popularity and family status, then it is only by showing humility and patience with the degrading factors of knowledge, that one can truly attain the knowledge.
* Similarly, he must carefully select the person he is going to acquire knowledge from. He should not take knowledge, except from one whose qualifications are legitimately established, whose good religious qualities are evident, whose reputation is reliable and whose respectability is well known. Muhammad Ibn Sireen, Maalik Ibn Anas and many more of the Salaf have said: "Indeed, this knowledge is the Religion! So look carefully towards whom you take your Religion from." 
* He must look towards his teacher with an eye of respect and reverence, for indeed this is the best way of deriving benefit from him. When some of our Salaf would go to study with their teacher, they would give something away in charity and say: "O Allaah, conceal my teacher’s defects from me and do not cause the blessing of his knowledge to be taken away from me." Ar-Rabee', the companion of Ash-Shaafi'ee (rahimahullaah) would say: "I never dared to drink water in the presence of Ash-Shaafi'ee, while he was looking at me, for fear of (upsetting) him." And it is reported that some of the predecessors used to say: "From the rights that a teacher has over you is that: You should greet all the people generally with Salaam, but specify him apart from them with a particular greeting. You should sit in front facing him. You should not point toward his direction with your hand nor should you wink at him with your eye. You should not say to him: ‘Such and such person says the opposite of what you say!’ You must not backbite anyone in his presence. You should not consult your partner’s advice while in his gathering. You should not grab onto his garment if he should rise nor should you persistently bother him if he is fatigued. And you should not mind anyone that prolongs his company with him."
* He should enter into the presence of his teacher with a clear and purified mind. Thus, his heart should be free of any matters that would prevent him from giving his full attention. He must not enter into his presence without first asking his permission, if his teacher is in a place which necessitates that his asking for permission be sought. He should greet those that attend his gathering with Salaam, when entering, and specify his teacher with a particularized greeting, apart from them. He should not step over the people with disregard, but rather he should sit where the rows of the gathering come to an end, until the teacher grants him permission to draw closer or he understands from the other students that are sitting that they prefer for him to advance. He should not cause anyone to get up from his place and if someone loves for him to sit in his place, then he should not accept, following the example of Ibn 'Umar (raa). This is unless there is a benefit in his sitting up front, for the ones present, or the teacher orders them to do that. He should not sit in the middle of the learning circle, unless there is a necessity. He should not sit between two companions, unless he has their permission to do so. And if space is made for him in a gathering, he should sit and crouch himself in order to fit.
* He must safeguard and preserve his studies by being diligent and persisting in it during all times in which he has the ability to do so. He should not satisfy himself with a little when he has the ability to attain more. He should not over burden himself with things that he cannot handle, for fear that it will cause him to grow tired and postpone what he desires to attain (of knowledge). This matter varies according to each individual and his circumstances. He must exert himself severely in trying to make free time for himself, maintain vivacity and eagerness, develop a strong and healthy body, have observant and conscious mind and to possess few preoccupations, such as the obstacles that fall in one’s way when he becomes a leading figure or when he gets promoted to a high position. 'Umar Ibn Al-Khattaab (raa) said: "Acquire knowledge before you become leaders. For indeed, when you become leaders, followed by the people, you will be prevented from acquiring knowledge, due to the elevation of your position and excessiveness of your preoccupations." [Kitaab-ul-‘Ilm (The Book of Knowledge) of Abu Khaithama] This statement contains the meaning of Imaam Ash-Shaafi'ee's words: "Acquire knowledge before you are given leadership, for when you become a leader, then there is no recourse for you, except knowledge."
The Etiquettes of a Teacher
* The teacher must make his intention purely for the sake of Allaah when teaching. He should not use his knowledge to seek an honorable position in the society nor should he charge any fee in exchange for his knowledge. He should not prefer nearness to the rich and luxurious, whilst distancing himself away from the poor.
* He must characterize himself with the good manners mentioned in the texts of the Revelation, as well as the praiseworthy qualities and the pleasant traits that Allaah has guided towards. This includes abstaining from the worldly life, possessing little of its luxuries and not being tested by it and its inhabitants. Other characteristics include generosity, kindness, polite manners, cheerfulness in the face, forbearance and patience. He must be void of being able to grant little benefit to others. He must observe the qualities of piety, humility, tranquility, respect and humbleness. He should refrain from laughing and joking too much. He must observe the prescribed duties of the Religion, such as trimming the mustache, clipping the fingernails, combing the beard and ceasing to have a bad attitude. He must adorn his outer and inner characteristics with the Sunnah of the Prophet (saws). It has been reported on 'Umar Ibn Al-Khattaab (raa) that he said: "Whosoever displays good characteristics to us, we will have good thoughts about him and love him. And whosoever displays bad characteristics to us, we will have bad thoughts about him and hate him."
* He must free himself from performing any matters that have been ruled detestable (makrooh) as well as from indulging excessively in matters that have been ruled allowable (mubaah), while in the presence of his students. He should always have his students see him obeying Allaah and remembering Him much (dhikr), and he must preserve that condition. He must be cautious of all the dangers that are to be heeded, such as jealousy, showing-off, being amazed with oneself, and having contempt for others.
* The teacher must be gentle with the one who takes knowledge from him. He must welcome him graciously and be kind to him, according to that person's state of being. He must always offer him sincere advice, for indeed, the Messenger of Allaah (saws) said: "The Religion is sincerity (advising): to Allaah, His Book, His Messenger, the Muslim leaders and their common folk." 
* He must be gentle and compassionate with the one that seek knowledge from him, and he must look after his needs, just as he looks after the needs of his own child or his own self. He must be humble in the presence of those that frequently go to him and learn from him.
* He must preserve his habit of teaching students, causing that to have a significant place in his necessities. And when sitting amongst his students, he must rid himself of any affairs that cause him to become preoccupied. He must give to each one of his students, according to what is befitting to them, individually. Thus he should not exceed with one that doesn’t show that he wants to go a step further nor should he undercut from one that does want to progress. He should compliment anyone that shows excellence in his studies, as long as he doesn’t fear that affliction will befall him, by his becoming amazed with himself or something other than that. And he must show strictness with whoever deserves it, so long as he doesn't fear that it will chase him away. He should not be jealous of any of his students, if one of them begins to display proficiency in the subject matter being studied. Nor should he continuously mention the favors that Allaah has bestowed on him, in that student's presence. For indeed, being jealous of others is forbidden, upon a strict forbiddance. So how can he be jealous, especially of the student, who holds the status of a child?
 An authentic narration on Muhammad Ibn Sireen reported by Muslim in the introduction to his Saheeh
 Reported by Muslim At-Tirmidhee, An-Nasaa'ee and others. Ibn Al-Atheer (ra) said: "Naseeha (Sincerity/Advising) is a word that entails many meanings. It is the desiring of good for the one who is being advised. The meaning of sincerity to Allaah is possessing good beliefs in regards to His Oneness and sincerity of intention in His worship. Sincerity to the Book of Allaah means believing in it and acting upon what is contained within it. Sincerity to His Messenger means believing in his (saws) prophethood and rendering obedience to what he has commanded and what he has forbidden. Sincerity to the Muslim leaders means obeying them in matters of truth and not setting out against them in rebellion, if they should be oppressive. And sincerity to Muslim common folk means advising and directing them towards their needs and benefits.