Sunan Abi Dawud, Hadith 2593

Narrated Abdullah ibn Umar: When the Messenger of Allah sat on his camel to go out on a journey, he said: "Allah is Most Great" three times. Then he said: "Glory be to Him Who has made subservient to us, for we had not the strength for it, and to our Lord do we return. O Allah, we ask Thee in this journey of ours, uprightness, piety and such deeds as are pleasing to Thee. O Allah, make easy for us this journey of ours and make its length short for us. O Allah, Thou art the Companion in the journey, and the One Who looks after the family and property in our absence." When he returned, he said these words adding: "Returning, repentant, serving and praising our Lord." The Prophet and his armies said: "Allah is Most Great" when they went up to high ground; and when armies said: "Allah is most Great" when they went up to high ground; and when they descended, they said: "Glory be to Allah." So the prayer was patterned on that.

حَدَّثَنَا الْحَسَنُ بْنُ عَلِيٍّ، حَدَّثَنَا عَبْدُ الرَّزَّاقِ، أَخْبَرَنَا ابْنُ جُرَيْجٍ، أَخْبَرَنِي أَبُو الزُّبَيْرِ، أَنَّ عَلِيًّا الأَزْدِيَّ، أَخْبَرَهُ أَنَّ ابْنَ عُمَرَ عَلَّمَهُ أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم كَانَ إِذَا اسْتَوَى عَلَى بَعِيرِهِ خَارِجًا إِلَى سَفَرٍ كَبَّرَ ثَلاَثًا ثُمَّ قَالَ ‏"‏ ‏{‏ سُبْحَانَ الَّذِي سَخَّرَ لَنَا هَذَا وَمَا كُنَّا لَهُ مُقْرِنِينَ * وَإِنَّا إِلَى رَبِّنَا لَمُنْقَلِبُونَ ‏}‏ اللَّهُمَّ إِنِّي أَسْأَلُكَ فِي سَفَرِنَا هَذَا الْبِرَّ وَالتَّقْوَى وَمِنَ الْعَمَلِ مَا تَرْضَى اللَّهُمَّ هَوِّنْ عَلَيْنَا سَفَرَنَا هَذَا اللَّهُمَّ اطْوِ لَنَا الْبُعْدَ اللَّهُمَّ أَنْتَ الصَّاحِبُ فِي السَّفَرِ وَالْخَلِيفَةُ فِي الأَهْلِ وَالْمَالِ ‏"‏ ‏.‏ وَإِذَا رَجَعَ قَالَهُنَّ وَزَادَ فِيهِنَّ ‏"‏ آيِبُونَ تَائِبُونَ عَابِدُونَ لِرَبِّنَا حَامِدُونَ ‏"‏ ‏.‏ وَكَانَ النَّبِيُّ صلى الله عليه وسلم وَجُيُوشُهُ إِذَا عَلَوُا الثَّنَايَا كَبَّرُوا وَإِذَا هَبَطُوا سَبَّحُوا فَوُضِعَتِ الصَّلاَةُ عَلَى ذَلِكَ ‏.‏

sunnah.com