The Shiva sahasranama is a "list of a thousand names" of Shiva, one of the most important deities in Hinduism. In Hindu tradition a sahasranama is a type of devotional hymn (Sanskrit: stotra) listing many names of a deity. The names provide an exhaustive catalog of the attributes, functions, and major mythology associated with the figure being praised. The Shiva Sahasranama is found in Shiv Mahapuran and many other scriptures such as Ling Puran. As per Shiv Mahapuran when Vishnu was unable to defeat the demons after many attempts he prayed to Shiv who granted him the Sudarshan Chakra for fighting the demons
There are at least eight different versions of the Shiva sahasranama. The version appearing in Book 13 (Anuśāsanaparvan) of the Mahabharata is considered the kernel of this tradition. The eight versions analyzed by Ram Karan Sharma are:
Linga Purana (version 1, LP 1.65.54-168) is close to the Mahabharata Anushasanaparvan version.
Linga Purana (version 2, LP 1.98.27-159) has some passages in common with LP version 1, but also with other sources
Mahabharata (Śāntiparvan version). The critical edition of the Mahabharata does not include this version; it is considered part of book 12 (Śāntiparvan), but is relegated to Appendix 28 in the critical edition, representing a late addition to the text. The Gita Press edition restores it as part of the main text, as verses 12.284.68-180.
Vayu Purana (1.30.179-284) is almost the same as the Mahabharata Śāntiparvan version.
Brahmanda Purana (38.1.1-100) is almost the same as the Vayu Purana version.
Mahābhāgavata Upapurana (67.1-125) appears to be of comparatively recent origin.
^English translation: Mahabharata 13.17 translated by Kisari Mohan Ganguly (published between 1883 and 1896). This is the source for the version presented in Chidbhavananda, who refers to it being from the Mahabharata but does not explicitly clairify which of the two Mahabharata versions he is using. See Chidbhavananda, p.5.