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

Ibn Mughaffal reported: Allah's Messenger (PBUH) ordered the killing of dogs and then said: what is the trouble with them (the people of Medina)? How dogs are nuisance to them (the citizens of Medina)? He then permitted keehing of dogs for hunting and (the protection of) herds. Translation Not Available

Book Ref: Sahih Muslim Book 22 Hadith 3814
Web Ref:  Sahih Muslim Book 10 Hadith 1573 a