”I studied the exoteric sciences, devoting thirty years to their study, until I had mastered them and was proficient in them,” says the great imam, as-sayyid ash-shaykh Muhammad ibn Ali as-Sanusi.
He had studied in Algeria with local teachers, before moving to Fez where he studied for 15 years. While in Fez, he took the Shadhiliyya Nasiriyya, an elite branch of the Shadhili tariqa that is given only to ulamaa. He also took the Darqawiyya and Tijaniyya, and took the Qur’an from shaykh al-Tijani himself.
But the shaykh felt that he had not yet found his long-sought goal, the supreme Sufi master whom he had always sought, but not yet found or encountered.
He travelled to the east and studied two or three years in Cairo. He looked for his spiritual guide in Cairo, but a hidden wali, unknown to him, spoke to him by name and said, “The man you want is in Mecca and you must go there to meet him.”
So he continued to Mecca to perform the pilgrimage, and there he saw the sayyid Ahmad ibn Idris.
“I listened to his lectures on the exoteric and esoteric sciences- his discernment was unparalleled and was confirmed for every science. But I did not accept him for not following the madhhabs. I said to myself: He is a Kharijite!
Then I saw the Prophet, salla Allahu alayhi wa Alihi wa sallam, one night.”Oh Messenger of Allah, I request of you the illumination”.
He, salla Allahu alayhi wa Alihi wa sallam, said: “Your illumination will be at the hands of Ahmad ibn Idris.
But when I awoke, I was doubtful and concealed my vision, telling no one about it. Then I saw the Prophet, salla Allahu alayhi wa Alihi wa sallam, a second time and again I sought the illumination from him, but he answered as he had the first time. Then I saw him, salla Allahu alayhi wa Alihi wa sallam, a third time and he said to me: “Your illumination will be at the hands of Ahmad b. Idris.”
So I said to myself “Should I not seek from him the knowledge of the Way, since this is something different from the madhhabs”? Then I went to him in order to listen carefully to the lessons in the exoteric sciences. I had sat down in front of him when he said to me:
‘O Muhammad, is not the vision that you saw once, twice, and a third time sufficient for you?’
He then laid bare to me my innermost heart before I had said a word to him. On that day I submitted to him and received from his hands the Way of the people (tariq al-qawm).”
Shaykh as-Sanusi says of his instruction at the hands of the great master:
“I took from him, may Allah be pleased with him, numerous and comprehensive sciences and branches of knowledge concerning hadith, tafseer, fiqh, and tasawwuf and suchlike, together with his brilliant disputations with the ahl al-ta’wil, which were of a kind that you would scarcely find written by anyone other than him. As for the religious science reserved for the elite of the elite, he was the imam of the gnostics and their tutor.”