Anjaneya, Hanuman is considered to be an Avatar of Shiva and some Purans mention Him as the Son of Lord Shiva.
Though Hanuman was an ardent Devotee of Lord Rama, He was a devotee of Shiva as well.
But there is an incident narrated in the Valmiki Ramayana, where Hanuman uprooted the Shiva Linga!
Lord Rama, after the killing of Ravana, was advised to perform Prayaschitta, Atonement, for killing Ravana a Vedic scholar and a devotee of Shiva in Rameswaram, within two days from the date of killing Ravana.
Rama accordingly reached Rameswaram,while Hanuman and Jatayu were sent to search for A Shiva Linga
As they were delayed, Sita, asked by Rama , to. form a Shiva Linga out of sand , as the suspicious Muhurtha was about to end..
Sita did and at the same time Hanuman with the Linga was sighted.
Hanuman was upset that the Linga was not used by Sita .
Rama asked him to remove the Linga by the Sita so that Hanuman’s Linga could be installed,
Hanuman tried to uproot it, but finding the job tough, coiled His Tail around the Linga and uprooted it.
This fell few miles off Rameswaram and it is called Hanuman Pallam, Hanuman Pit.
In the process Hanuman’s tail was cut off.
Hanuman realized his folly and Rama advised him to perform Pooja for Shiva at Thirukkurankaval .
Hanuman did so..
Lord Hanuman realized his folly. It was pre-ordained that the lingam prepared by Lord Sita was to be used for the rituals and sought forgiveness from Lord Rama and Sita to regrow his tail.
Lord Rama suggested to Lord Hanuman that he seek forgiveness from Lord Shiva instead and suggested that Lord Hanuman visit Thirukurungaval and worship Lord Shiva there to get back his tail. Hence the place has acquired its name, Tirukurunkaval (Place where Lord Shiva was worshipped by a monkey-faced God) The testimony to this story is that it is one of the few Lord Shiva temples in the world, with a shrine to Lord Hanuman facing Lord Shiva.
It is also a metaphorical message that Lord Shiva and Lord Vishnu (of which Lord Rama was an incarnation) are the same.
Thirukkurankukka/ Thirukkurankaval is one of the 275 Thevara Shivasthalam of Lord Shiva in Myladuthurai, Nagapattinam District, Tamil Nadu. This is one of the 5 prominent temples of Lord Shiva ending its name with ‘Ka’ and they are: Thiruvanaikka, Thirukkodikka, Thirunellikka, Thirkolakka and Thirukkurankukka.
Presiding deity – Lord Thirukunthalanathar/Kunthaleswarar /Kundalakarneswarar with his consort Goddess Sri Kunthalambikai
Mangalasasanam – Thirunavukkarasar
Theertham – Hanumath Theertham
Sthalavruksham – Mango tree
Worshipped by – Lord Anjaneya
Sannidhis – Lord Ganesha, Lord Nandikeshwara, Lord Subramanya with his consorts Goddesses Sri Valli & Deivayanai, Lord Surya, Lord Bhairava, Idols of Anjaneya, Anjaneya, Goshtamurtham – Lord Dakshinamurthi, Goddess Sri Durga,
Festivals – Maha Shivaratri, Masi Makam, Amavasya, Chithirai Utsavam, Arudra Darisanam, Aippasi Annabhishekam, Thirukarthikai, Markazhi Utsavam