The Messenger of Allah ﷺ performed the prayer of fear at Dhu Qarad, a place in the territory of Banu Sulaym. The people formed two rows behind him, one row facing the enemy and another row behind him. He led the row nearest to him in one rakah, then this group withdrew to the position of the other group and the other group advanced to the position of the first, and he led them in another rakah.
حدثنا وكيع حدثنا سفيان عن أبي بكر بن أبي الجهم عن عبيد الله بن عبد الله بن عتبة
صلى رسول الله ﷺ صلاة الخوف بذي قرد أرض من أرض بني سليم فصف الناس خلفه صفين صفا يوازي العدو وصفا خلفه فصلى بالصف الذي يليه ركعة ثم نكص هؤلاء إلى مصاف هؤلاء وهؤلاء إلى مصاف هؤلاء فصلى بهم ركعة أخرى
Its isnad is sahih. Abu Bakr bin Abu Jahm is here attributed to his grandfather, and he is Abu Bakr bin Abdullah bin Abu Jahm, who is among the trustworthy narrators, and his hadith is found in Muslim and elsewhere. The hadith has already appeared at 21484.