I came to Madinah to meet the companions of Muhammad ﷺ, and there was no man among them I wished to meet more than Ubayy.The prayer was called, and Umar came out with the companions of the Messenger of Allah ﷺ. I stood in the first row. Then a man came, looked at the faces of the people, recognized all of them except me, pushed me aside, and stood in my place. I could not concentrate on my prayer.When he had finished praying, he said, "My son, may Allah not distress you. I did not do to you what I did out of ignorance. Rather, the Messenger of Allah ﷺ said to us, 'Be in the row immediately behind me.' I looked at the faces of the people and recognized all of them except you."Then he began to speak, and I never saw men crane their necks toward anything as they craned their necks toward him. I heard him say, "The people of the covenant have perished, by the Lord of the Kaabah. Indeed, I do not grieve over them, but I grieve over the Muslims who will perish along with them."And behold, it was Ubayy. The wording of the hadith is that of Sulayman bin Dawud.
حدثنا سليمان بن داود ووهب بن جرير قالا حدثنا شعبة عن أبي جمرة قال سمعت إياس بن قتادة يحدث
أتيت المدينة للقي أصحاب محمد ﷺ ولم يكن فيهم رجل ألقاه أحب إلي من أبي فأقيمت الصلاة وخرج عمر مع أصحاب رسول الله ﷺ فقمت في الصف الأول فجاء رجل فنظر في وجوه القوم فعرفهم غيري فنحاني وقام في مكاني فما عقلت صلاتي فلما صلى قال يا بني لا يسوءك الله فإني لم آتك الذي أتيتك بجهالة ولكن رسول الله ﷺ قال لنا كونوا في الصف الذي يليني وإني نظرت في وجوه القوم فعرفتهم غيرك ثم حدث فما رأيت الرجال متحت أعناقها إلى شيء متوحها إليه قال سمعته يقول هلك أهل العقدة ورب الكعبة ألا لا عليهم آسى ولكن آسى على من يهلكون من المسلمين وإذا هو أبي والحديث على لفظ سليمان بن داود
No references are available.
Its isnad is sahih. It is found in Nasai 2/88, and Hakim graded it sahih in 4/226, no. 8602 (Dar al-Fikr edition), and Dhahabi agreed with him. Something similar is in Abu Dawud 1/178, no. 674, and Ibn Majah 1/312, no. 976. And likewise in Muslim 1/323, no. 432.