Al-Adab Al-Mufrad, Book 42, Hadith 37 (In-Book)

Abu Hurayra reported that the Messenger of Allah, may Allah bless him and grant him peace, said, "The young person greets the old person, the person walking greets the person sitting down, and the small group greets the large group."

حَدَّثَنَا أَحْمَدُ بْنُ أَبِي عَمْرٍو قَالَ‏:‏ حَدَّثَنِي أَبِي قَالَ‏:‏ حَدَّثَنِي إِبْرَاهِيمُ، عَنْ مُوسَى بْنِ عُقْبَةَ، عَنْ صَفْوَانَ بْنِ سُلَيْمٍ، عَنْ عَطَاءِ بْنِ يَسَارٍ، عَنْ أَبِي هُرَيْرَةَ قَالَ‏:‏ قَالَ رَسُولُ اللهِ صلى الله عليه وسلم‏:‏ يُسَلِّمُ الصَّغِيرُ عَلَى الْكَبِيرِ، وَالْمَاشِي عَلَى الْقَاعِدِ، وَالْقَلِيلُ عَلَى الْكَثِيرِ‏.‏

sunnah.com