Vairocanavajra's biography was written by his Tibetan student,
Zhang Yudrakpa Tsöndru Drakpa, shortly after his death and was intended to be a eulogy to his master. Vairochanavajra was born in the 12th century in the city of Sonapura in the region of
Dakshina Kosala which is just south of
Magadha. From the age of 12, he travelled with his uncle, who was a non-Buddhist, to different parts of
India including
Western India,
Magadha, and
Varanasi. During his travels, he met a
yogin who initiated him into the practice of the
bodhisattva,
Manjushri. After this, he travelled to the monastery of
Nalanda where he studied under a
yogin called Surapela who belonged to the
Kayastha caste. For the next eight years, Surapela taught Vairochanavajra about
alchemy,
arts and
logic. In particular, he was taught the
Dohā songs and the teachings of
Maitripada. After this, he held a
tantric gathering in the forests surrounding Nalanda with other masters including Siri and Mathanata. Vairochanavajra also came into contact with a scholar from the
Vikramashila monastery called Gunaraksita. From him, Vairochanavajra received teachings on the
Prajnaparamita, the
Madhyamaka collection of teachings, and more complex tantras like the
Guhyasamāja. During this period, he received teachings from other masters including
Abhayakaragupta, Śarana, Jayākara and Dānaraksita. After this period of learning, Vairocanavajra is said to have "travelled the roads of twenty-four countries" and entered the country of the
Western Xia via
Tibet. He was appointed the priest of a ruler called Mu thang bu of the Shing kun City but was kept as a prisoner and not allowed to leave due to his knowledge of mercurial
alchemy which was believed to lengthen one's life. Eventually, he aroused the displeasure of this King and was released and travelled to
Tibet. ==Teachings==