The Vedas state that yagna or penance is integral for the protection of the world and a0ll the living beings in it. Performance of yagnas with the only motive of the welfare of the entire world is equal to penance of the highest order. For the Lord, the act of protection and sustenance which He does incessantly is the yagna. This spirit of ideal penance is exemplified in His incarnations, especially as Varaha and Rama, pointed out Sri B. Damodhara Dikshitar in a lecture.
The successive births of the demons as Hiranyaksha and Hiranyakasipu, Kumbhakarna and Ravana and later as Dantavaktra and Sisupala came about as a result of the curse of the Sanatkumara sages who were angered when the celestial gatekeepers Jaya and Vijaya denied them entry to the Lord’s presence. Cursed by the sages, the gatekeepers felt penitent and begged the Lord to alleviate them from the punishment. The sages too felt that they had been hasty in condemning the gatekeepers. The Lord assured them that this happened because of His sankalpa. He would incarnate to quell evil and establish dharma and these demons would meet their end at His hands.
At the time of creation, Brahma realised that the earth got submerged in the nether regions of Rasatala. Unable to proceed further, Brahma meditated on the Supreme Lord who took the form of a small boar of the size of a thumb.
Emerging from Brahma’s nostril this form grew to a colossal size and plunged into the ocean to save the earth (Bhu). As He lifted the earth on His white tusks against the background of his huge body, Hiranyaksha of irresistible power confronted Him with his mace. The Lord vanquished him and brought the earth to safety. The epithet Yagna Varaha signifies the Lord’s selfless and dedicated effort to protect and restore the earth to its place.
Yagna Rama performs this penance in vanquishing Kumbhakarna and Ravana and in Krishna avatar this is repeated in the annihilation of Dantavaktra and Sisupala. In addition, the ethical code prescribed in the Vedas for human beings is illustrated in Rama avatar.