Of all the hundreds of maladies that can befall a musician, stage fright and performance anxiety are most devastating, but given time and preparation, they can be cured.
Stage fright is a psychological reaction to a persons fear of public embarrassment. Every performer or musician at some point in their career will face stage fright or performance anxiety of some degree. The symptoms range from minor physical discomforts such as a stomach ache to more extreme symptoms such as shortness of breath or panic attacks. Whether you are performing a musical piece or giving a public speech there are two primary things that influence the degree to which a person experiences stage fright or performance anxiety: Lack of preparation and individual personality issues.
Stage fright is usually a result of the performer fearing that they will make a mistake in public and be ridiculed for that mistake. In most amateur or student performance environments the possibility of such ridicule is slight, as in most cases the people watching the performance are friends or fellow students. Realizing this fact can often take the sting out of the more serious symptoms, but it will rarely go away completely. Because of this fact, the only way to get rid of performance anxiety is to make sure that the performer is an expert on his or her material or music. In the case of an instrumentalist, performing on his or her instrument, the music must be thoroughly rehearsed for weeks or even months before the performance. Each time the the music is practiced the performer will more deeply ingrain the material into their brain until, ideally, the music is memorized. Once a performer reaches this point in their preparation another aspect of stage fright is greatly reduced because the performer knows without a doubt that they can play the material accurately and reliably.
You may think that practice and rehearsal are the same thing but in truth they are very different when it comes to overcoming stage fright. Practicing refers to individual solo work on the music or other material to be performed. Rehearsal (in this context) means the act of performing the material in public or with a small group of friends or teachers. To overcome stage fright a person must be totally prepared to perform the material they have been assigned. Only once a person has managed to learn their material can that person move forward into rehearsing the piece with his peers or other members of an ensemble. If the material has not been practiced enough, then even the idea of rehearsing it in a group will bring about a sudden onset of stage fright. Again, practice until it is perfect, then rehearse it with the rest of the group before performing in public.