كتاب صلاة المسافرين وقصرها
6  
The Book of Prayer - Travellers
(55)
Chapter: It is recommended to pray two rak`ah before Maghrib
(55)
باب اسْتِحْبَابِ رَكْعَتَيْنِ قَبْلَ صَلاَةِ الْمَغْرِبِ ‏
Sahih Muslim 837

Anas b. Malik reported:

When we were in Medina, the moment the Mu'adhdhin made the call to the sunset prayer, the people hastened to the pillars of the mosque and prayed two rak'ahs with the result that any stranger coming into the mosque would think that the obligatory prayer had been observed owing to the number who were praying then.
وَحَدَّثَنَا شَيْبَانُ بْنُ فَرُّوخَ، حَدَّثَنَا عَبْدُ الْوَارِثِ، عَنْ عَبْدِ الْعَزِيزِ، - وَهُوَ ابْنُ صُهَيْبٍ - عَنْ أَنَسِ بْنِ مَالِكٍ، قَالَ كُنَّا بِالْمَدِينَةِ فَإِذَا أَذَّنَ الْمُؤَذِّنُ لِصَلاَةِ الْمَغْرِبِ ابْتَدَرُوا السَّوَارِيَ فَيَرْكَعُونَ رَكْعَتَيْنِ رَكْعَتَيْنِ حَتَّى إِنَّ الرَّجُلَ الْغَرِيبَ لَيَدْخُلُ الْمَسْجِدَ فَيَحْسِبُ أَنَّ الصَّلاَةَ قَدْ صُلِّيَتْ مِنْ كَثْرَةِ مَنْ يُصَلِّيهِمَا ‏.‏
Reference : Sahih Muslim 837
In-book reference : Book 6, Hadith 367
USC-MSA web (English) reference : Book 4, Hadith 1821
  (deprecated numbering scheme)