Hanash narrates from Sayyiduna Ali (may Allah be pleased with him): The sun was eclipsed, and Sayyiduna Ali (may Allah be pleased with him) led the people in prayer. In it he recited Surah Ya-Sin or something like it, then bowed for about as long as his recitation, then raised his head from the bowing and said: 'Sami' Allahu liman hamidah' (Allah hears the one who praises Him). Then he stood for about the length of the surah (Ya-Sin), supplicating, and he said the takbir. Then he performed a bowing as long as his recitation, then said: 'Sami' Allahu liman hamidah.' Then he stood for about the length of the surah, then bowed for the same length, until there were four bowings. Then he said: 'Sami' Allahu liman hamidah,' then prostrated. Then he rose for the second rak'ah and did in it just as in the first rak'ah. Then he remained seated supplicating, and kept urging (them), until the sun became bright. Then he told them that the Prophet (peace and blessings be upon him) had done the same.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب صلاة الخسوف / 6329