Once the god of creation Brahma and the god of protection mahA vishNu entered in an argument on deciding who is greater. When those two great gods were fighting between themselves, the Greatest of all Lord shiva who is formless and transcends everything appeared as a pillar of flame. God told Brahma and vishNu that whoever finds the head or the foot of His flame form would be considered greater. brahmA took the form of swan ( ha.msam ) and set out to reach the top of the Fire. vishNu became a wild pig to see the foot of the Fire. Where are the limits for the infinite God ? They could not succeed in spite of their heavy effort. They realized their mistake and the peerless greatness of Lord shiva. The God who can never be reached by ego appears as the form of love to those who surrender to Him. Lord shiva appeared in the form of shiva li.ngam (which is the shape of flame) for their benefit. They worshiped that oldest form of Him and got blessed. The God who came to bless them from the Flame, from the li.ngam is known as li.ngodbhava (2). This incident is depicted in shiva mahA purANam (1) and many other scriptures.
As the God stood as pillar of flame, the natural adornment for the Lord is Holy Ash. (As ash would be found on the surface of the fire). As the God stood as the Luminat Flame that stood up the shiva sahasranAma hails God as Urdva retas and the shiva aShtottara as hiraNya retas. The hymn that starts nidhana pataye namaH, refers to many similarities of Flame and shivalinga.
God is formless, attributeless and omnipresent. This state is called arUpa (formless). For the benefit of the pashus, He took the form of shiva li.ngam which is neither form nor formless but is a symbol. This symbol of Him is called arUparUpam (formless form). He took many forms out of His mercy to bless all, which are called rUpams. (2). shaivam worships the God in all these three states. The oldest form that the formless God took namely the shiva li.ngam is called sadAshiva mUrtam and is worshipped in the altar of His abodes (temples). The forms that He later took which are called mAhEshwara mUrtam are worshipped in the outer circles in a temple.