In Krutha Yuga the two gate keepers of Sri Vaikuntam on curse of Rishies were born as cruel Hiranya Brothers, Younger Hiranyaksha was killed by Mahavishnu in the Avatharam of Varaha, for his harmful deeds Sri Boomidevi.
The elder Hiranyakasipu concentrated his mind and did serious Thapas for so many years. As a result of his Thapas, he got boons from Brahma Deva, that he will never meet the death by human beings, animals, earth and sky, by any instruments in and out of the houses etc.
Then Hiranya, on the Power of the boons, gave much troubles to Rishies and Devas and compelled them to pray them as "HIRANYAYA NAMA" only; and ordered that there is no other god to pray except him. As all were afraid of Hiranya, no Yagas and Deva Poojas were done. Then, worried Devas and Rishies with Brahma, prayed Lord Sri Narayana to get relief from Hiranya.
Therefore Sri Mahavishnu, determined to kill Hiranya and blessed them. Hiranya had a son named Prahaladha. He was naturally very pious to Lord Mahavishnu. So he refused to say "Hiranyaya Nama" but he only prayed "OM NAMO NARAYANA" Hiranya tried to change Prahaladha to pray his name insted of Lord Vishnu, in so many ways personally and through Gurns, but it proved in vain Prahaladha never said "Hiranyaya Nama" but he prayed bravely "OM NAMO NARAYANA" with the company of other boys