Nafi' narrates from Sayyiduna Abdullah bin Umar (may Allah be pleased with him) that the Messenger of Allah (peace and blessings be upon him) set out for Umrah, and the polytheists of Makkah came between him (peace and blessings be upon him) and the House. He (peace and blessings be upon him) slaughtered his sacrifice and shaved his head at al-Hudaybiyah. It was settled that he (peace and blessings be upon him) would perform Umrah the following year, but would not bring weapons, and would stay only as long as they (the disbelievers) wished. He (peace and blessings be upon him) performed Umrah the following year as had been agreed in the truce with them. When he had stayed there for three days, they said: Now leave; so he (peace and blessings be upon him) left.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الحج / 10081