The Prophet ﷺ said, "Satan ties three knots at the back of the head of one of you when he sleeps. At each knot he says, 'You have a long night ahead, so sleep on.'"On another occasion he said, "He strikes at each knot, saying, 'You have a long night ahead.'"He continued, "When the person wakes up and remembers Allah , one knot is undone. When he performs ablution, the second knot is undone. When he prays, all the knots are undone, and he begins his morning energetic and in good spirits. Otherwise, he wakes up ill-tempered and sluggish."
حدثنا سفيان عن أبي الزناد عن الأعرج
عن النبي ﷺ قال يعقد الشيطان على قافية رأس أحدكم ثلاث عقد بكل عقدة يضرب عليك ليلا طويلا فارقد وقال مرة يضرب عليه بكل عقدة ليلا طويلا قال وإذا استيقظ فذكر الله عز وجل انحلت عقدة فإذا توضأ انحلت عقدتان فإذا صلى انحلت العقد وأصبح طيب النفس نشيطا وإلا أصبح خبيث النفس كسلانا
Its isnad is sahih. Muslim related it (1:216) and Nasai (238-239), both through Sufyan bin Uyayna, with this same isnad. Malik related it in Muwatta (176) from Abu Zinad, with the same wording. Bukhari related it (3:20-22), and Abu Dawud (1306) [1:504 of Awn al-Mabud], both through Malik. Bukhari also related it again (6:239-240), and Ibn Majah (1:206), through two other routes from Abu Hurairah.Munziri mentioned in Targhib (1:213) that Ibn Khuzayma related something similar in his Sahih, adding at the end, "So untie the knots of Shaytan, even if only with two units of prayer. Shaytan ties..." Ibn Athir said, the word qafiyah means the nape of the neck, though it has also been said to mean the back of the head, or its middle. What is meant is that he weighs it down in sleep and prolongs it, as if he had bound it with cords and tied it with three knots.Khattabi said in Maalim (1261 of Tahzib Sunan), what is meant is the back of the head, and from this the last word of a line of poetry is called qafiyah. I said to a Bedouin who came to us, "Where did you camp?" He replied, "In the qafiyah of that place," naming a spot I recognized.As for the phrase "a long night stretches ahead of you," Nawawi said in his commentary on Muslim (6:65), this is how it appears in most copies of Sahih Muslim in our lands. Qadi likewise transmitted it from the majority's version as "alayka laylan tawilan" with the accusative case, functioning as a warning exclamation. Some transmitted it as "alayka laylun tawilun" with the nominative, meaning "a long night remains for you." Hafiz mentioned in Fath al-Bari (3:20-21) that all the transmission routes in Bukhari have the nominative case. He then said that in Abu Musab's transmission in Muwatta from Malik it appears as "alayka laylan tawilan," which is also the version of Ibn Uyayna from Abu Zinad, as found in Muslim.Iyad said, the majority's transmission from Muslim has the accusative, as a warning exclamation, while whoever uses the nominative treats it as the beginning of a sentence, meaning "remaining upon you," or with an implied verb, meaning "it has remained."Qurtubi said, the nominative is preferable in terms of meaning, because it is more effective for deception, in that Shaytan is informing him of the length of the night and then commanding him to sleep by saying "so sleep." Whereas if it is read in the accusative as a warning exclamation, it would contain nothing but a command to persist in prolonged sleep, in which case the phrase "so sleep" would be redundant. Shaytan's purpose in this is to make him procrastinate about getting up and to confuse the matter for him.As for the word "kaslana," it is likewise established in the three original manuscripts as declinable, with the alif retained after the nun, and it is marked with two fathas above the nun in the two handwritten copies. In the rest of the transmissions we have seen, it appears as "kaslan" as indeclinable, and I consider what is established in the original manuscripts to be more sound, on the basis that both declinability and indeclinability are permissible for this word, since it is established that its feminine form is "kaslana." In Lisan, quoting Jawhari, "and the feminine... is kasla and kaslana." Indeed, the author of Qamus restricted himself to "kaslana" alone, and his commentator Zubaydi followed up on this, saying, it is an Asadi dialectal form and a rare one, whereas "kasla," like "qatla," according to our shaykh, is the well known form, which the author overlooked. I say, Ibn Sidah did mention it.Since it is established that its feminine form is "kaslana," it may then be treated as declinable, whether or not it has another feminine form on the pattern of "fala." Suyuti said in Jam al-Jawami (1:30), on the subject of factors preventing declinability, a word being an adjective ending in an extra alif and nun, on condition that its feminine form follows the pattern of "fala," like "sakran" and "sakra," or "rayyan" and "rayya." It has also been said that the condition is rather that its feminine form not follow the pattern of "falana," regardless of whether it also has a feminine form on the pattern of "fala" or not... and if a word of the "falan" pattern has a feminine form on the pattern of "falana," it is declinable by unanimous agreement.