Emperor Janamejaya was the son of Maharaja Parikshit and great-grandson of Arjuna the valiant warrior hero of the Mahabharata epic. He took up the Kuru throne following the death of father. His significance comes as the listener of the first narration of the Mahabharata, narrated by Vaishampayana, student of Vyasa.
Emperor Janamejaya was responsible for the retelling of the famous epic Mahabharata a story of Janamejaya's ancestors from the time of Bharata up to the great Kurukshetra war between his great grandfathers the Pandavas and their paternal cousins the Kauravas. This was recited to him by the sage Vaishampayana after he asked the sage about his ancestors.
Emperor Janamejaya ascended to the throne of Hastinapura upon the death of his father Parikshita. According to legend, Parikshita, the lone descendant of the House of Pandu, had died of snakebite. He had been cursed by a sage to die so, the curse having been consummated by the serpent-chieftain Takshak.
Janamejaya bore a deep grudge against the serpents for this act, and thus decided to wipe them out altogether. He attempted this by performing a great Sarpa satra - a sacrifice that would destroy all living serpents.
Just as he was about to begin the sacrifice, the rishi Vyasa arrived with a host of rishis. The sages told Janamejaya that to avenge himself on all Nagas, for the action of one, who was after all consummating a curse, would be unrighteous, and not worthy of one descended from the Pandavas themselves. Janamejaya desists from completing the sacrifice. Upon Janamejaya's expressed curiosity as to the lives and actions of his forefathers, Vyasa's disciple Vaishampayana then narrates the MahÄ�bhÄ�rata, at the spot where the homa was to have to have been held.
The mass sacrifice was started on the banks of the river Arind at Bardan, now Known as Parham, a corrupt form of Parikshitgarh, A masonry tank said to have been built by Emperor Janamejaya to mark the site of the sacrificial pit, known as Parikshit kund, still exists in Mainpuri district. Close to this village a very large and high khera containing the ruins of a fort and some stone sculptures has been found . It is said to date back to the time of Emperor Parikshita. A popular local legend is that as a consequence of the virtues of that sacrifice snakes are still harmless in this place and its neighborhood.
The day of the homa is today revered by Hindus as the Nag Panchami ritual.