Legend has it that the Shivling worshipped in the famous Mahabaleshwar Temple in Gokarna was gifted to Ravana,
the demon king in Ramayana, by Shiva. As per the popular story, Ravana conquered the
world and turned towards Kailash, the abode of Shiva. Ravana attempted to uproot
the Holy Mountain and tried to shake it. Shiva
just pressed his toe on the Mountain and Ravana was crushed by the weight of
the mountain.
Thus Gokarna got the Shivling which originally
belonged to Ravana.
Ravana who realized the omnipotence of Shiva immediately
started singing the Sama Veda to impress Mahadev.
Shiva was impressed by Ravana’s piety and gave him a
Shivling.
Shiva promised Ravana that no one will be able to conquer
him as long as the Shivling is worshipped in Lanka.
Shiva put a condition that if the Shivling was kept down
before reaching Lanka, then it will not move from the place.
Ravana carried the Shivling to Lanka but on the way at
Gokarna he wanted to take bath. So he gave the Shivling to a little boy and
asked him to not to keep it down. The boy agreed. But put a condition that
Ravana should return before he counted till hundred.
Ravana got delayed and the boy kept the Shivling down and
despite of numerous attempts Ravana could not move the Shivling.
The boy in reality was Ganesha who did not want Ravana to
become invincible.